diff --git a/docs/contributing/testing.md b/docs/contributing/testing.md index d8e07f1c85..d4311240eb 100644 --- a/docs/contributing/testing.md +++ b/docs/contributing/testing.md @@ -64,7 +64,7 @@ See [Conformance Testing in Kubernetes](https://github.com/kubernetes/community/ ### Running against a new cluster -By adding the `--up` flag, `kubetest2` will spin up a new cluster. In most cases, you also need to add a few additional flags, such as `--networking`. See `kubetest2 kops --help` for the full list. +By adding the `--up` flag, `kubetest2` will spin up a new cluster. Flags can be passed to the `kops create cluster` command via the `--create-args` flag. In most cases, you also need to add a few additional flags. See `kubetest2 kops --help` for the full list. ```shell kubetest2 kops \ @@ -72,9 +72,9 @@ kubetest2 kops \ --up \ --cloud-provider=aws \ --cluster-name=my.testcluster.com \ + --create-args="--networking calico" \ --kops-binary-path=${KOPS_ROOT}/bazel-bin/cmd/kops/linux-amd64/kops \ --kubernetes-version=v1.20.2 \ - --networking calico \ --test=kops \ -- -- \ diff --git a/tests/e2e/kubetest2-kops/deployer/deployer.go b/tests/e2e/kubetest2-kops/deployer/deployer.go index f401051365..5ec019085c 100644 --- a/tests/e2e/kubetest2-kops/deployer/deployer.go +++ b/tests/e2e/kubetest2-kops/deployer/deployer.go @@ -49,7 +49,6 @@ type deployer struct { Env []string `flag:"env" desc:"Additional env vars to set for kops commands in NAME=VALUE format"` CreateArgs string `flag:"create-args" desc:"Extra space-separated arguments passed to 'kops create cluster'"` KopsBinaryPath string `flag:"kops-binary-path" desc:"The path to kops executable used for testing"` - Networking string `flag:"networking" desc:"The networking mode to use"` StateStore string `flag:"-"` TemplatePath string `flag:"template-path" desc:"The path to the manifest template used for cluster creation"` diff --git a/tests/e2e/kubetest2-kops/deployer/up.go b/tests/e2e/kubetest2-kops/deployer/up.go index a34ffcf9f2..e42cdce081 100644 --- a/tests/e2e/kubetest2-kops/deployer/up.go +++ b/tests/e2e/kubetest2-kops/deployer/up.go @@ -125,10 +125,6 @@ func (d *deployer) createCluster(zones []string, adminAccess string) error { args = append(args, "--master-size", "s-8vcpu-16gb") } - if d.Networking != "" { - args = append(args, "--networking", d.Networking) - } - if d.CreateArgs != "" { // TODO: we should only set the above flags if they're not in CreateArgs // allowing any flag to be overridden