kpt
kpt copied to clipboard
kpt live apply --inventory-policy=force
Describe your problem
I have previously deployed a package but lost track of that inventory / configuration.
I would like to re-deploy the package with a new inventory name and forcibly switch resources to be incorporated into the new inventory, without having to delete the existing resources.
I was expecting that --inventory-policy=force
would exist and let me do this, but it seems the only way to forcibly acquire existing resources from an old inventory is to edit the resources directly with kpt.
The underlying library do allow for "taking over" resources from other resources, but that option is not currently exposed in the kpt cli. We should allow this to happen. As part of doing that we need to also verify that updates to the package the resource previously belonged to recognize the change in ownership in all situations.