Skip to content

Commit

Permalink
default --use-deprecated-gcs to true
Browse files Browse the repository at this point in the history
  • Loading branch information
sbueringer committed May 22, 2024
1 parent ce4e4f5 commit 35d7bbd
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 5 deletions.
7 changes: 4 additions & 3 deletions tools/setup-envtest/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -41,12 +41,13 @@ setup-envtest use -i --use-env
# sideload a pre-downloaded tarball as Kubernetes 1.16.2 into our store
setup-envtest sideload 1.16.2 < downloaded-envtest.tar.gz

# Per default envtest binaries are downloaded from:
# If --use-deprecated-gcs is set to false envtest binaries are downloaded from:
# https://raw.githubusercontent.com/kubernetes-sigs/controller-tools/master/envtest-releases.yaml
# To download from a custom index use the following:
setup-envtest use --index https://custom.com/envtest-releases.yaml
# Note: In controller-runtime v0.19.0 --use-deprecated-gcs will default to false.
setup-envtest use --use-deprecated-gcs=false --index https://custom.com/envtest-releases.yaml

# To download from the kubebuilder-tools GCS bucket: (default behavior before v0.18)
# To download from the kubebuilder-tools GCS bucket: (default behavior until v0.18)
# Note: This is a Google-owned bucket and it might be shutdown at any time
# see: https://github.com/kubernetes/k8s.io/issues/2647#event-12439345373
# Note: This flag will also be removed soon.
Expand Down
4 changes: 2 additions & 2 deletions tools/setup-envtest/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -50,15 +50,15 @@ var (
binDir = flag.String("bin-dir", "",
"directory to store binary assets (default: $OS_SPECIFIC_DATA_DIR/envtest-binaries)")

useDeprecatedGCS = flag.Bool("use-deprecated-gcs", false, "use GCS to fetch envtest binaries. Note: This is deprecated and will be removed soon. For more details see: https://github.com/kubernetes-sigs/controller-runtime/pull/2811")
useDeprecatedGCS = flag.Bool("use-deprecated-gcs", true, "use GCS to fetch envtest binaries. Note: This is deprecated and will be removed soon. For more details see: https://github.com/kubernetes-sigs/controller-runtime/pull/2811. In controller-runtime v0.19.0 this flag will default to false")

// These flags are only used with --use-deprecated-gcs.
remoteBucket = flag.String("remote-bucket", "kubebuilder-tools", "remote GCS bucket to download from (only used with --use-deprecated-gcs)")
remoteServer = flag.String("remote-server", "storage.googleapis.com",
"remote server to query from. You can override this if you want to run "+
"an internal storage server instead, or for testing. (only used with --use-deprecated-gcs)")

// This flag is only used if --use-deprecated-gcs is not set or false (default).
// This flag is only used if --use-deprecated-gcs is set to false.
index = flag.String("index", remote.DefaultIndexURL, "index to discover envtest binaries (only used if --use-deprecated-gcs is not set, or set to false)")
)

Expand Down

0 comments on commit 35d7bbd

Please sign in to comment.