Skip to content

Commit e210be7

Browse files
committed
Go: Preserve environment variables in ApplyProxyEnvVars
1 parent 0f78e11 commit e210be7

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

go/extractor/util/registryproxy.go

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -91,6 +91,9 @@ func ApplyProxyEnvVars(cmd *exec.Cmd) {
9191

9292
checkEnvVars()
9393

94+
// Preserve environment variables
95+
cmd.Env = os.Environ()
96+
9497
if proxy_address != "" {
9598
cmd.Env = append(cmd.Env, fmt.Sprintf("HTTP_PROXY=%s", proxy_address))
9699
cmd.Env = append(cmd.Env, fmt.Sprintf("HTTPS_PROXY=%s", proxy_address))

0 commit comments

Comments
 (0)