diff --git a/pkg/executor/common.go b/pkg/executor/common.go index 0a281c8dca2..00b934d258b 100644 --- a/pkg/executor/common.go +++ b/pkg/executor/common.go @@ -45,7 +45,7 @@ const ( var RunnerEnvVars = []corev1.EnvVar{ { Name: "DEBUG", - Value: os.Getenv("DEBUG"), + Value: getOr("DEBUG", "false"), }, { Name: "RUNNER_ENDPOINT", diff --git a/pkg/executor/containerexecutor/containerexecutor_test.go b/pkg/executor/containerexecutor/containerexecutor_test.go index f11ac56f194..2e5a34bedae 100644 --- a/pkg/executor/containerexecutor/containerexecutor_test.go +++ b/pkg/executor/containerexecutor/containerexecutor_test.go @@ -130,7 +130,7 @@ func TestNewExecutorJobSpecWithArgs(t *testing.T) { assert.NotNil(t, spec) wantEnvs := []corev1.EnvVar{ - {Name: "DEBUG", Value: ""}, + {Name: "DEBUG", Value: "false"}, {Name: "RUNNER_ENDPOINT", Value: ""}, {Name: "RUNNER_ACCESSKEYID", Value: ""}, {Name: "RUNNER_SECRETACCESSKEY", Value: ""},