Skip to content
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

Delete multiple deployments simultaneously via single kapp delete cmd #50

Closed
scothis opened this issue Nov 12, 2019 · 6 comments
Closed
Labels
discussion This issue is not a bug or feature and a conversation is needed to find an appropriate resolution wontfix This will not be worked on

Comments

@scothis
Copy link
Contributor

scothis commented Nov 12, 2019

It would be nice to delete multiple deployment with a single command

kapp delete -a app1 -a app2 -a app3

Currently, only the last app (app3) is deleted and the others are ignored. This is common behavior with cobra, but can be surprising for users.

@cppforlife cppforlife added the discussion This issue is not a bug or feature and a conversation is needed to find an appropriate resolution label Nov 13, 2019
@cppforlife
Copy link
Contributor

the alternative option is to disallow multiple -a specifications.

im not sure if we should allow multiple -a on delete as then deploy command becomes asymmetric with delete. thoughts about alternative mentioned above?

@scothis
Copy link
Contributor Author

scothis commented Nov 13, 2019

the alternative option is to disallow multiple -a specifications.

Cobra doesn't make this easy

@cppforlife
Copy link
Contributor

cppforlife commented Nov 13, 2019

can just switch to string slice type and assert on length == 1.

@scothis
Copy link
Contributor Author

scothis commented Nov 13, 2019

can just switch to string slice type and assert on length == 1.

The docs for the command will then be misleading as they will show the flag as an array. Also, this pattern applies to every other flag. I'd leave it alone and let Cobra manage the behavior generically.

@cppforlife
Copy link
Contributor

but if so, what does it mean to kapp deploy -a foo -a another-one ...?

@cppforlife cppforlife changed the title Delete multiple deployments simultaneously Delete multiple deployments simultaneously via single kapp delete cmd Nov 13, 2019
@cppforlife
Copy link
Contributor

after thinking some more, i think at this point kapp should stick with one deployment for -a flag for now to maintain consistency with other commands.

@cppforlife cppforlife added the wontfix This will not be worked on label Jan 21, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
discussion This issue is not a bug or feature and a conversation is needed to find an appropriate resolution wontfix This will not be worked on
Projects
None yet
Development

No branches or pull requests

2 participants