Upgrading the Traefik Hub Agent¶
This document demonstrates how to upgrade an existing Traefik Hub Agent installation in different environments.
Kubernetes¶
Refresh the helm chart to get the newest version and then re-run the installation command:
helm repo update
helm upgrade hub-agent traefik/hub-agent \
--reuse-values --namespace hub-agent
Docker¶
Stop the Hub Agent container.
Update the version and start the container again:
# Launch the Hub Agent for Traefik
docker run -d --volume /var/run/docker.sock:/var/run/docker.sock \
--restart="on-failure" \
--network=traefik-hub \
--pull=always \
--name=hub-agent ghcr.io/traefik/hub-agent-traefik:vX.X.X run \
--auth-server.advertise-url=http://hub-agent \
--hub.token=XXXXX \
--traefik.host=traefik \
--traefik.tls.insecure=true
vX.X.X
is the latest version of the containerhub.token=XXXXX
is your Traefik Hub token
Docker Compose¶
Manually¶
Stop docker-compose
:
docker-compose down
Update the tag of the container to the latest version:
services:
# Start the agent with the latest version
hub-agent:
image: ghcr.io/traefik/hub-agent-traefik:vX.X.X
vX.X.X
is the latest version of the container
Start docker-compose again
:
docker-compose-hub-agent.yaml up -d
Automated¶
Stop docker-compose
, pull the latest container image and start docker-compose
again:
docker-compose down
docker-compose pull
docker-compose-hub-agent.yaml up -d