-
Notifications
You must be signed in to change notification settings - Fork 890
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
Karmadactl join: default use current context #2956
Karmadactl join: default use current context #2956
Conversation
A little idea, maybe we can use the name of the current context to join the karmada when the clustername is not filled in. |
/retest |
f7db8d9
to
2e9b1d0
Compare
Codecov Report
@@ Coverage Diff @@
## master #2956 +/- ##
=======================================
Coverage 38.32% 38.32%
=======================================
Files 207 207
Lines 18999 18999
=======================================
Hits 7282 7282
- Misses 11287 11288 +1
+ Partials 430 429 -1
Flags with carried forward coverage won't be shown. Click here to find out more.
Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here. |
2e9b1d0
to
23622c6
Compare
23622c6
to
b3d655b
Compare
pkg/karmadactl/join/join.go
Outdated
flags.StringVar(&j.ClusterContext, "cluster-context", "", | ||
"Context name of cluster in kubeconfig. Only works when there are multiple contexts in the kubeconfig.") | ||
"Context name of cluster in kubeconfig. Please make sure this context exists in the cluster, default use current context.") |
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.
"Context name of cluster in kubeconfig. Please make sure this context exists in the cluster, default use current context.") | |
"Name of cluster context in kubeconfig. The current context is used by default.") |
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.
OK, but my e2e cannot pass. I'll check it later.
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.
It seems we also need to update the e2e, because it using the old process.
b3d655b
to
c5f6df2
Compare
Signed-off-by: helen <haitao.zhang@daocloud.io>
c5f6df2
to
c47b536
Compare
/lgtm It could resolve some confusion of new users that don't unfamiliar the relationship between /cc @RainbowMango |
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.
/approve
I updated the release-note.
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: RainbowMango 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 |
Hi @RainbowMango , it should be
to
|
oh, right. |
Signed-off-by: helen haitao.zhang@daocloud.io
What type of PR is this?
/kind feature
What this PR does / why we need it:
The current context should be used instead of the clustername when the
--cluster-context
parameter is not set.Which issue(s) this PR fixes:
Fixes #
Special notes for your reviewer:
When I don't want to provide the
--cluster-context
parameter and encounter obstacles customizing the clustername, clustername become the--cluster-context
, but I don't have such a context.Does this PR introduce a user-facing change?: