vmware-tanzu / velero

Backup and migrate Kubernetes applications and their persistent volumes
https://velero.io
Apache License 2.0
8.66k stars 1.4k forks source link

Allow velero cli more kubectl flag access (specifically `--as` && `--as-group`) #3939

Open georgettica opened 3 years ago

georgettica commented 3 years ago

Describe the problem/challenge you have When running the velero cli some commands require imporsonation (the --as flag) which is not exposed via the cli

Describe the solution you'd like That the cli tooling will use the official tooling like is done here https://github.com/dastergon/kubectl-janitor/blob/6799fcccc2ace001634e177c5e4d1805496e4276/pkg/cmd/janitor.go#L46

Anything else you would like to add: I can contact @dastergon to help migrate to this format, but I wanted to ask your opinion before creating a PR

Environment:

N/A

This is a feature request and is currently happening on the latest version of the velero cli

Vote on this issue!

This is an invitation to the Velero community to vote on issues, you can see the project's top voted issues listed here.
Use the "reaction smiley face" up to the right of this comment to vote.

zubron commented 3 years ago

Hi @georgettica - Could you provide a bit more information about which commands you need to use impersonation with?

is currently happening on the latest version of the velero cli

I'm not sure what you mean by this. I'm not aware of which commands support this flag.

georgettica commented 3 years ago

I needed to do velero plugin add which patches the deployment And basically any command that does k8s operations in case I need to use another user (who is elevated) to do these operations

georgettica commented 2 years ago

Any traction on this? @zubron