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 --selector flag support #52917

Merged
merged 1 commit into from Oct 5, 2017

Conversation

Projects
None yet
7 participants
@juanvallejo
Member

juanvallejo commented Sep 22, 2017

Release note:

NONE

Adds --selector option to kubectl drain,cordon,uncordon, performing
each action on a list of nodes matching the given label.

If at least one node fails to be cordoned/uncordoned, the command will
continue to operate on any remaining nodes, uninterrupted, reporting
any errors it encounters along the way.

If at least one node fails to be drained, the command will halt, printing
the immediate error encountered, and a list of nodes yet to be drained
(including the node that just failed to be drained).

cc @kubernetes/sig-cli-misc @fabianofranz @soltysh

@k8s-ci-robot

This comment has been minimized.

Show comment
Hide comment
@k8s-ci-robot

k8s-ci-robot Sep 22, 2017

Contributor

Hi @juanvallejo. Thanks for your PR.

I'm waiting for a kubernetes member to verify that this patch is reasonable to test. If it is, they should reply with /ok-to-test on its own line. Until that is done, I will not automatically test new commits in this PR, but the usual testing commands by org members will still work. Regular contributors should join the org to skip this step.

I understand the commands that are listed here.

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. I understand the commands that are listed here.

Contributor

k8s-ci-robot commented Sep 22, 2017

Hi @juanvallejo. Thanks for your PR.

I'm waiting for a kubernetes member to verify that this patch is reasonable to test. If it is, they should reply with /ok-to-test on its own line. Until that is done, I will not automatically test new commits in this PR, but the usual testing commands by org members will still work. Regular contributors should join the org to skip this step.

I understand the commands that are listed here.

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. I understand the commands that are listed here.

@k8s-ci-robot

This comment has been minimized.

Show comment
Hide comment
@k8s-ci-robot

k8s-ci-robot Sep 22, 2017

Contributor

@juanvallejo: Reiterating the mentions to trigger a notification:
@kubernetes/sig-cli-misc

In response to this:

Release note:

NONE

Adds --selector option to kubectl drain,cordon,uncordon, performing
each action on a list of nodes matching the given label.

If at least one node fails to be cordoned/uncordoned, the command will
continue to operate on any remaining nodes, uninterrupted, reporting
any errors it encounters along the way.

If at least one node fails to be drained, the command will halt, printing
the immediate error encountered, and a list of nodes yet to be drained
(including the node that just failed to be drained).

cc @kubernetes/sig-cli-misc @fabianofranz @soltysh

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.

Contributor

k8s-ci-robot commented Sep 22, 2017

@juanvallejo: Reiterating the mentions to trigger a notification:
@kubernetes/sig-cli-misc

In response to this:

Release note:

NONE

Adds --selector option to kubectl drain,cordon,uncordon, performing
each action on a list of nodes matching the given label.

If at least one node fails to be cordoned/uncordoned, the command will
continue to operate on any remaining nodes, uninterrupted, reporting
any errors it encounters along the way.

If at least one node fails to be drained, the command will halt, printing
the immediate error encountered, and a list of nodes yet to be drained
(including the node that just failed to be drained).

cc @kubernetes/sig-cli-misc @fabianofranz @soltysh

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.

@fabianofranz

This comment has been minimized.

Show comment
Hide comment
@fabianofranz

fabianofranz Sep 22, 2017

Contributor

/ok-to-test

Contributor

fabianofranz commented Sep 22, 2017

/ok-to-test

@juanvallejo

This comment has been minimized.

Show comment
Hide comment
@juanvallejo

juanvallejo Sep 22, 2017

Member

/retest

Member

juanvallejo commented Sep 22, 2017

/retest

@sttts

This comment has been minimized.

Show comment
Hide comment
@sttts

sttts Sep 25, 2017

Contributor

/unassign
/assign @fabianofranz

Contributor

sttts commented Sep 25, 2017

/unassign
/assign @fabianofranz

@juanvallejo

This comment has been minimized.

Show comment
Hide comment
@juanvallejo

juanvallejo Sep 25, 2017

Member

/retest

Member

juanvallejo commented Sep 25, 2017

/retest

@soltysh

This comment has been minimized.

Show comment
Hide comment
@soltysh

soltysh Sep 28, 2017

Contributor

The change itself lgtm, but you need to fix test and please squash your changes into single commit.
@kubernetes/sig-cli-bugs ptal

Contributor

soltysh commented Sep 28, 2017

The change itself lgtm, but you need to fix test and please squash your changes into single commit.
@kubernetes/sig-cli-bugs ptal

@juanvallejo

This comment has been minimized.

Show comment
Hide comment
@juanvallejo

juanvallejo Oct 2, 2017

Member

/test pull-kubernetes-unit

Member

juanvallejo commented Oct 2, 2017

/test pull-kubernetes-unit

@juanvallejo

This comment has been minimized.

Show comment
Hide comment
@juanvallejo

juanvallejo Oct 2, 2017

Member

@soltysh thanks, went ahead and squashed; test has been fixed

Member

juanvallejo commented Oct 2, 2017

@soltysh thanks, went ahead and squashed; test has been fixed

@juanvallejo

This comment has been minimized.

Show comment
Hide comment
@juanvallejo
Member

juanvallejo commented Oct 3, 2017

@fabianofranz

This comment has been minimized.

Show comment
Hide comment
@fabianofranz

fabianofranz Oct 4, 2017

Contributor

/lgtm
/approve no-issue

Contributor

fabianofranz commented Oct 4, 2017

/lgtm
/approve no-issue

@k8s-ci-robot k8s-ci-robot added the lgtm label Oct 4, 2017

@k8s-merge-robot

This comment has been minimized.

Show comment
Hide comment
@k8s-merge-robot

k8s-merge-robot Oct 4, 2017

Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: fabianofranz, juanvallejo

Associated issue requirement bypassed by: fabianofranz

The full list of commands accepted by this bot can be found here.

Needs approval from an approver in each of these OWNERS Files:

You can indicate your approval by writing /approve in a comment
You can cancel your approval by writing /approve cancel in a comment

Contributor

k8s-merge-robot commented Oct 4, 2017

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: fabianofranz, juanvallejo

Associated issue requirement bypassed by: fabianofranz

The full list of commands accepted by this bot can be found here.

Needs approval from an approver in each of these OWNERS Files:

You can indicate your approval by writing /approve in a comment
You can cancel your approval by writing /approve cancel in a comment

@fabianofranz

This comment has been minimized.

Show comment
Hide comment
@fabianofranz

fabianofranz Oct 4, 2017

Contributor

/kind enhancement

Contributor

fabianofranz commented Oct 4, 2017

/kind enhancement

@k8s-merge-robot

This comment has been minimized.

Show comment
Hide comment
@k8s-merge-robot

k8s-merge-robot Oct 5, 2017

Contributor

Automatic merge from submit-queue (batch tested with PRs 53454, 53446, 52935, 53443, 52917). If you want to cherry-pick this change to another branch, please follow the instructions here.

Contributor

k8s-merge-robot commented Oct 5, 2017

Automatic merge from submit-queue (batch tested with PRs 53454, 53446, 52935, 53443, 52917). If you want to cherry-pick this change to another branch, please follow the instructions here.

@k8s-merge-robot k8s-merge-robot merged commit 65cca36 into kubernetes:master Oct 5, 2017

13 of 14 checks passed

pull-kubernetes-e2e-kubeadm-gce Parent Job Status Changed: Job triggered.
Submit Queue Queued to run github e2e tests a second time.
Details
cla/linuxfoundation juanvallejo authorized
Details
pull-kubernetes-bazel-build Job succeeded.
Details
pull-kubernetes-bazel-test Job succeeded.
Details
pull-kubernetes-cross Skipped
pull-kubernetes-e2e-gce-bazel Job succeeded.
Details
pull-kubernetes-e2e-gce-etcd3 Jenkins job succeeded.
Details
pull-kubernetes-e2e-gce-gpu Job succeeded.
Details
pull-kubernetes-e2e-kops-aws Jenkins job succeeded.
Details
pull-kubernetes-kubemark-e2e-gce Jenkins job succeeded.
Details
pull-kubernetes-node-e2e Jenkins job succeeded.
Details
pull-kubernetes-unit Jenkins job succeeded.
Details
pull-kubernetes-verify Jenkins job succeeded.
Details

@juanvallejo juanvallejo deleted the juanvallejo:jvallejo/support-multiple-node-selection branch Oct 5, 2017

k8s-merge-robot added a commit that referenced this pull request Oct 24, 2017

Merge pull request #54083 from juanvallejo/jvallejo/update-resource-b…
…uilder-cmd-drain

Automatic merge from submit-queue. If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>.

update resource selector - kubectl drain

Followup to #52917

**Release note**:
```release-note
NONE
```

Updates resource builder in cmd/drain.go to parse resource args similar to other commands.

cc @liggitt

openshift-merge-robot added a commit to openshift/origin that referenced this pull request Dec 21, 2017

Merge pull request #17616 from juanvallejo/jvallejo/add-selector-oc-d…
…rain

Automatic merge from submit-queue (batch tested with PRs 17072, 17616).

Add --selector, --pod-selector flags `oc adm drain`

Fixes #17554
Fixes #17563
Fixes https://bugzilla.redhat.com/show_bug.cgi?id=1525340

Picks kubernetes/kubernetes#52917, kubernetes/kubernetes#54083, and kubernetes/kubernetes#56864 to bring in `--selector` and `--pod-selector` flag support to `oc adm drain`.

cc @openshift/cli-review @deads2k @dustymabe
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment