velero/pkg/install
Suraj Banakar ff1a31db4a
Support cli uninstall (#3399)
* Add uninstall cmd
- init fn to uninstall velero
- abstract dynamic client creation to a separate fn
- creates a separate client per unstructured resource
- add delete client for CRDs
- export appendUnstructured
- add uninstall command to main cmd
- export `podTemplateOption`
- uninstall resources in the reverse order of installation
- fallback to `velero` if no ns is provided during uninstall
- skip deletion if the resource doesn't exist
- handle resource not found error
- match log formatting with cli install logs
- add Delete fn to fake client
- fix import order
- add changelog
- add comment doc for CreateClient fn

Signed-off-by: Suraj Banakar <suraj@infracloud.io>

* Re-use uninstall code from test suite
- move helper functions out of test suite
- this is to prevent cyclic imports
- move uninstall helpers to uninstall cmd
- call them from test suite
- revert export of variables/fns from install code
- because not required anymore

Signed-off-by: Suraj Banakar <suraj@infracloud.io>

* Revert `PodTemplateOption` -> `podTemplateOption`

Signed-off-by: Suraj Banakar <suraj@infracloud.io>

* Use uninstall helper under VeleroUninstall
- as a wrapper
- fix import related errors in test suite

Signed-off-by: Suraj Banakar <suraj@infracloud.io>
2021-03-04 14:16:40 -05:00
..
daemonset.go Allow feature flags to be passed from install CLI (#2503) 2020-05-06 10:52:44 -07:00
daemonset_test.go Allow feature flags to be passed from install CLI (#2503) 2020-05-06 10:52:44 -07:00
deployment.go Use label to select Velero deployment in plugin cmd (#3447) 2021-02-10 20:42:04 -05:00
deployment_test.go Allow feature flags to be passed from install CLI (#2503) 2020-05-06 10:52:44 -07:00
doc.go Add location resources and tests (#1277) 2019-03-13 11:23:00 -06:00
install.go Support cli uninstall (#3399) 2021-03-04 14:16:40 -05:00
resources.go Use label to select Velero deployment in plugin cmd (#3447) 2021-02-10 20:42:04 -05:00
resources_test.go create CRB with velero-<namespace> (#2886) 2020-10-13 16:13:42 -07:00