Skip to content

Commit 11c6c18

Browse files
committed
Only run when debugging or test mode is enabled
1 parent 99fcc7b commit 11c6c18

File tree

2 files changed

+18
-14
lines changed

2 files changed

+18
-14
lines changed

lib/start-proxy-action.js

Lines changed: 10 additions & 8 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

src/start-proxy-action.ts

Lines changed: 8 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -80,12 +80,14 @@ async function run(startedAt: Date) {
8080
// Check the environment for any configurations which may affect the proxy.
8181
// This is a best effort process to give us insights into potential factors
8282
// which may affect the operation of our proxy.
83-
try {
84-
checkProxyEnvironment(logger, language);
85-
} catch (err) {
86-
logger.debug(
87-
`Unable to inspect runner environment: ${util.getErrorMessage(err)}`,
88-
);
83+
if (core.isDebug() || util.isInTestMode()) {
84+
try {
85+
checkProxyEnvironment(logger, language);
86+
} catch (err) {
87+
logger.debug(
88+
`Unable to inspect runner environment: ${util.getErrorMessage(err)}`,
89+
);
90+
}
8991
}
9092

9193
const ca = generateCertificateAuthority(

0 commit comments

Comments
 (0)