Reinstalling the Kubernetes Operator Reinstalling the Kubernetes Operator

Reinstalling the Kubernetes Operator

Joel Watson Joel Watson

There are many potential situations where you might need to reinstall the Kubernetes Operator. Fortunately, you can perform this operation without any downtime for your applications.

 

Step 1: Backup Your CRDs

Uninstalling the operator will leave any Kubernetes secrets you've created (including the one used to store synced secrets) in place, so the only resource you need to ensure you have backups of are the CRDs that were put in place. To back these up, run the following command:

kubectl get dopplersecrets --namespace doppler-operator-system -o yaml > doppler-crds.yml

 

Step 2: Uninstall the Operator

The next step is to uninstall the Doppler Kubernetes Operator helm chart.

 

Helm Installation

If you installed via Helm, you'll first need to find out the name it was installed under. To do that, run helm list:

❯ helm list
NAME NAMESPACE REVISION UPDATED STATUS CHART APP VERSION
doppler-operator default 1 2022-06-24 11:48:59.883345 -0500 CDT deployed doppler-kubernetes-operator-1.1.0

In the above example, the name of the install is doppler-operator. If you followed our documentation and used --generate-name, then the name may look more like doppler-kubernetes-operator-1656087587.

 

Once you have the name of the install, run the following command to uninstall it (use the name you found in place of doppler-operator below):

helm uninstall doppler-operator

 

Manual Installation

If you installed manually via kubectl, then you'll want to run the following command:

kubectl delete -f https://github.com/DopplerHQ/kubernetes-operator/releases/latest/download/recommended.yaml

 

Step 3: Reinstall the Operator

After uninstalling the helm chart, the next step is to reinstall it.

 

Helm Installation

If you installed via Helm, then run the following command:

helm install doppler-operator doppler/doppler-kubernetes-operator

 

Manual Installation

If you installed manually via kubectl, then run the following command:

kubectl apply -f https://github.com/DopplerHQ/kubernetes-operator/releases/latest/download/recommended.yaml

 

Step 4: Re-apply Your CRDs

Finally, you'll need to re-apply the CRDs you backed up in Step 1. To do that, run the following command:

kubectl apply -f doppler-crds.yml

After doing that, your installation should be back to its old state with a fresh install!

Was this article helpful?

1 out of 1 found this helpful