feat: automatic adoption of existing K8s resources
mumoshu opened this issue · 0 comments
mumoshu commented
#6 would allow us to adopt existing K8s resources as if they were installed by helm
. Let's go one step further by extending helm x apply
to automatically run helm x adopt
on first apply:
helm x apply \
--adopt-resources myns/deployment/myapp,myns/service/myapp \
--name myapp
./mychart
When the release myapp
does not exist on your cluster, this runs helm x adopt --resources myns/deployment/myapp,myns/service/myapp
and then helm x apply --name myapp ./mychart
.
On second and further runs helm-x
just runs helm x apply --name myapp ./mychart
.
This way, users can run helm x apply
whenever they need to install/upgrade a helm release, regardless of it needs to adopt first or not.