Skip to main content
Version: Deploy 22.3

Upgrading multi-node Docker deployments

This topic explains the process for upgrading multi-node Docker deployments.

Follow these steps to Upgrade Deploy active-active cluster setup,

Steps

  1. Make sure to read our docs for upgrade and release notes for each version you want to upgrade to.

  2. Stop the current running instances of Deploy docker containers which have an older version that needs to be upgraded. You do not need to stop the load balancer, mq and database containers. See the example below:

 # Shutdown deployments
docker-compose -f docker-compose-xld-ha.yaml -f docker-compose-xld-ha-workers.yaml stop xl-deploy-master xl-deploy-worker
  1. Update both files docker-compose-xld-ha.yaml and docker-compose-xld-ha-workers.yaml
  • Update the image with the new tag which represents the version you want to upgrade to, for both master and worker, for example:
 xl-deploy-master:
image: xebialabs/xl-deploy:9.5.1
  • Specify your DB connection details, to point to an old DB for both master and worker for example using environment variables such as XL_DB_URL
  • Include all volumes already being used with old docker images for both master and worker. In case of "conf" volume, make sure to also update any configurations required by new version "check release notes", before mounting it to new version of the container.
  • Update the environment variables to include FORCE_UPGRADE for master nodes, see below,
 environment:
- FORCE_UPGRADE=true
  1. You can use the run.sh script that is provided, to bring up the setup or perform it manually by following the steps mentioned below. Update the passwords to represent Passwords used in previous version.
# Set passwords
export XLD_ADMIN_PASS=admin
export RABBITMQ_PASS=admin
export POSTGRES_PASS=admin

# upgrade master nodes only
docker-compose -f docker-compose-xld-ha.yaml up --scale xl-deploy-master=3 -d

# get the IP of master nodes, change the container names if you are not inside a folder named "xl-deploy-ha"
export XLD_MASTER_1=$(docker inspect -f '{{range .NetworkSettings.Networks}}{{.IPAddress}}{{end}}' xl-deploy-ha_xl-deploy-master_1)
export XLD_MASTER_2=$(docker inspect -f '{{range .NetworkSettings.Networks}}{{.IPAddress}}{{end}}' xl-deploy-ha_xl-deploy-master_2)
export XLD_MASTER_3=$(docker inspect -f '{{range .NetworkSettings.Networks}}{{.IPAddress}}{{end}}' xl-deploy-ha_xl-deploy-master_3)
export XLD_LB=$(docker inspect -f '{{range .NetworkSettings.Networks}}{{.IPAddress}}{{end}}' xl-deploy-lb)

# Deploy the worker nodes, you can change the number of nodes here if you wish
docker-compose -f docker-compose-xld-ha-workers.yaml up --scale xl-deploy-worker=3 -d

# Print out the status
docker-compose -f docker-compose-xld-ha.yaml -f docker-compose-xld-ha-workers.yaml ps
  1. You can view the logs of individual containers using the docker logs <container_name> -f command.
  2. You can access Deploy UI at http://localhost:8080.