-
Notifications
You must be signed in to change notification settings - Fork 111
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
[Clusterloader2] Implement a clusterloader2 tester #53
Conversation
@@ -63,6 +63,17 @@ type deployer struct { | |||
verbosity int // --verbosity for kind | |||
} | |||
|
|||
func (d *deployer) Kubeconfig() (string, error) { |
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 isn't quite correct vs kind / client-go FYI ... https://github.com/kubernetes-sigs/kind/tree/master/pkg/cluster/internal/kubeconfig/internal/kubeconfig
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.
are you referring to https://github.com/kubernetes-sigs/kind/blob/master/pkg/cluster/internal/kubeconfig/internal/kubeconfig/paths.go#L30-L43 ?
I think we are only missing the KUBECONFIG env handling from there. will add as a follow up. This should solve the basic case when nothing is set.
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.
~HOME is also more complex on windows, off the top of my head.
I think this deployer should probably have it's own stable computed paths and use those consistently (like $HOME/.kube/kubetest2-kind-$cluster)
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.
yeah, I'm planning on sending kind deployer specific changes separately soon and the top-level artifacts organization changes, will fix this more robustly there.
Current change is only to make quick testing of the clusterloader2 tester locally with the kind deployer easy.
pkg/testers/clusterloader2/cl2.go
Outdated
TestOverrides string `desc:"Comma separated list of paths to the config override files. The latter overrides take precedence over changes in former files."` | ||
TestConfigs string `desc:"Comma separated list of paths to test config files."` | ||
Provider string `desc:"The type of cluster provider used (e.g gke, gce, skeleton)"` | ||
KubeConfig string `desc:"Path to kubeconfig"` |
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.
shouldn't we inject the kubeconfig env to all testers?
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 also allows us to do multi-file for multi-cluster)
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.
we already do, this is an override. And yeah clusterloader2 doesn't support multi kubeconfig yet :/
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.
the usage text should probably clarify that this is an override?
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.
done
@@ -90,8 +101,8 @@ func bindFlags(d *deployer) *pflag.FlagSet { | |||
return flags | |||
} | |||
|
|||
// assert that deployer implements types.Deployer | |||
var _ types.Deployer = &deployer{} | |||
// assert that deployer implements types.DeployerWithKubeconfig |
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.
Is there any deployer that doesn't have kubeconfig?
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.
Don't think so
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.
I think we should make this a standard part of the API for deployer, a requirement for kubetest2, but that can be a follow-up.
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.
ack
/lgtm |
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: amwat, BenTheElder 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 |
/hold cancel |
/cc @mm4tt as FYI |
@amwat: GitHub didn't allow me to request PR reviews from the following users: mm4tt, as, FYI. Note that only kubernetes-sigs members and repo collaborators can review this PR, and authors cannot review their own PRs. In response to this:
Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. |
/lgtm |
Create an initial implementation of clusterloader2 tester.
Currently requires having https://github.com/kubernetes/perf-tests checked out.
/cc @BenTheElder