Updating on Kubernetes
Select the Portainer update method which matches the original installation method used.
Method 1: Updating using Helm
Add the Portainer Helm repository by running the following commands. Ignore any warnings about the repo already being there:
helm repo add portainer https://portainer.github.io/k8s/
helm repo updateNext, run one of the following commands to update Portainer:
helm upgrade -n portainer portainer portainer/portainer \
--set tls.force=true --set enterpriseEdition.image.tag=sts --set enterpriseEdition.enabled=trueMethod 2: Updating using YAML Manifest
Option 1: Via the Portainer UI
The easiest way to update is to use the Portainer UI along with our manifest files. Copy the contents of the manifest file that matches the method you used to deploy Portainer:
Copy the contents of the relevant NodePort manifest file:
For an agent-only deployment, use one of the following manifests instead:
Copy the contents of the relevant Load Balancer manifest file:
For an agent-only deployment, use one of the following manifests instead:
Log into Portainer and connect to the Kubernetes environment where Portainer is installed. From the menu select Applications then select Create from manifest. Toggle Use namespace(s) specified from manifest to on, then enter portainer in the Name field.
From the Build method selection choose Web Editor and ensure Kubernetes is selected as the Deploy type. Paste the contents of the YAML file then click Deploy. Portainer will process the manifest and should return you to the login page once the update is complete.
Option 2: Via the command line
If you prefer to use the command line to update, you can do so using kubectl commands:
Log into the control node of your Kubernetes cluster and run one of the following commands:
For an agent-only deployment, use one of the following commands instead:
Log into the control node of your Kubernetes cluster and run one of the following commands:
For an agent-only deployment, use one of the following commands instead:
When the deployment is finished you will be able to log into Portainer. You should notice the new version number at the bottom-left of the Portainer UI.
Method 3: Force an update
If Portainer does not update after running the above commands, you can force a download of the latest image by running the following command:
Or, for an agent-only deployment, use this command instead:
Last updated
Was this helpful?