From 571bd38ea11f513ef2480257c2f51c2e92da3819 Mon Sep 17 00:00:00 2001 From: justinsb Date: Sat, 7 Jan 2023 17:22:52 -0500 Subject: [PATCH] kubetest: pass through KOPS_ARCH if set This allows us to test with a fast single-architecture build, useful when running kubetest locally. --- tests/e2e/kubetest2-kops/deployer/common.go | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/tests/e2e/kubetest2-kops/deployer/common.go b/tests/e2e/kubetest2-kops/deployer/common.go index 39f9cb0049..f45c4d835a 100644 --- a/tests/e2e/kubetest2-kops/deployer/common.go +++ b/tests/e2e/kubetest2-kops/deployer/common.go @@ -182,6 +182,14 @@ func (d *deployer) env() []string { fmt.Sprintf("KOPS_FEATURE_FLAGS=%v", d.featureFlags()), "KOPS_RUN_TOO_NEW_VERSION=1", }...) + + // Pass-through some env vars if set (on all clouds) + for _, k := range []string{"KOPS_ARCH"} { + if v := os.Getenv(k); v != "" { + vars = append(vars, k+"="+v) + } + } + if d.CloudProvider == "aws" { // Pass through some env vars if set for _, k := range []string{"AWS_PROFILE", "AWS_SHARED_CREDENTIALS_FILE"} {