-
Notifications
You must be signed in to change notification settings - Fork 2.7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add --extract-{ci,release}-bucket flags to kubetest #19620
Add --extract-{ci,release}-bucket flags to kubetest #19620
Conversation
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: spiffxp The full list of commands accepted by this bot can be found here. The pull request process is described here
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
This is to support migrating jobs to community-owned buckets: - ci: kubernetes-release-dev -> k8s-release-dev - release: kubernetes-release -> k8s-release The flags default to the google-owned kubernetes buckets, so jobs will require config changes to migrate kubetest ends up setting KUBERNETES_RELEASE_URL and calling out to kubernetes/kubernetes/cluster/get-kube.sh, which will then use the env var instead of any of its built-in defaults
1ebe169
to
d943f81
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
/lgtm
/hold
kubetest/main.go
Outdated
@@ -135,6 +137,8 @@ func defineFlags() *options { | |||
flag.StringVar(&o.dump, "dump", "", "If set, dump bring-up and cluster logs to this location on test or cluster-up failure") | |||
flag.StringVar(&o.dumpPreTestLogs, "dump-pre-test-logs", "", "If set, dump cluster logs to this location before running tests") | |||
flag.Var(&o.extract, "extract", "Extract k8s binaries from the specified release location") | |||
flag.StringVar(&o.extractCIBucket, "extract-ci-bucket", "kubernetes-release-dev", "Extract k8s CI binaries from the specified GCS bucket") | |||
flag.StringVar(&o.extractReleaseBucket, "extract-release-bucket", "kubernetes-release", "Extract k8s CI binaries from the specified GCS bucket") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
flag.StringVar(&o.extractReleaseBucket, "extract-release-bucket", "kubernetes-release", "Extract k8s CI binaries from the specified GCS bucket") | |
flag.StringVar(&o.extractReleaseBucket, "extract-release-bucket", "kubernetes-release", "Extract k8s release binaries from the specified GCS bucket") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This looks more like we need a way to override the two default hardcoded values, and not as much we need a way to customize both values in a specific run? Do we want to consider using experimental envs instead?
A more involved change would modify the corresponding strategies, but given the current maintenance state this minimal change LGTM.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This looks more like we need a way to override the two default hardcoded values, and not as much we need a way to customize both values in a specific run?
Migrating kubernetes-release is going to be more involved, so I was anticipating upgrade jobs for an existing release to the in-development release pulling from kubernetes-release and k8s-release-dev in the interim.
Do we want to consider using experimental envs instead?
I'd rather avoid envs and would prefer flags for less magic. Though admittedly kubernetes/kubernetes scripts by themselves will need envs eventually.
A more involved change would modify the corresponding strategies, but given the current maintenance state this minimal change LGTM.
Agreed. The current strategies parse themselves from the string passed to extract. I considered something like k8s-release-dev:ci/latest
, but as you said, that seemed like it more be more invasive.
Co-authored-by: Amit Watve <amwat@google.com>
/lgtm |
/hold cancel |
This is to support migrating jobs to community-owned buckets:
The flags default to the google-owned kubernetes buckets, so jobs
will require config changes to migrate
kubetest ends up setting KUBERNETES_RELEASE_URL and calling out
to kubernetes/kubernetes/cluster/get-kube.sh, which will then
use the env var instead of any of its built-in defaults
ref:
kubernetes/k8s.io#846 (comment)
ref: #19484 (comment)