Add "target-file" and "merge" flag to airshipctl cluster get-kubeconfig
command
#495
Labels
1-Core
Relates to airshipctl core components (i.e. go code)
enhancement
New feature or request
priority/medium
Default priority for items
size m
Milestone
Problem description (if applicable)
In addition to writing kubeconfig to stdout, it would be convenient to append kubeconfig or overwrite it.
If you use redirect kubeconfig to a file,
airshipctl cluster get-kubeconfig > ~/.airship/kubeconfig
, redirect>
immediately removes the content of the target file, which makes airshipctl unable to use it.The flag would allow using the flag and then overwrite the file.
Also, the additional flag can be used to merge the contexts from the new kubeconfig into a new one. This will allow extend kubeconfig instead of overriding its entire content.
Proposed change
Add two flags to
airshipctl cluster get-kubeconfig --target-file ~/.airship/kubeconfig --merge
--merge
(boolean) will allow merging contexts--target-file
(string) will allow specifying target fileNOTE: Actual flag names should be discussed.
The text was updated successfully, but these errors were encountered: