Skip to main content
Version: Deploy 24.1

This topic provides a guide for upgrading single-node Docker deployments.

If you want to upgrade a single node instance of Deploy using Docker, follow these steps: Note: Any failure during the caching setup will be captured in the logs but will not stop the application from starting.

  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 the Docker container having the old versions that need to be upgraded.
  3. Start a new Docker container with a new tag which represents the version you want to upgrade to. Consider these points:
    • Include all volumes already being used with old Docker images. In case of the /conf volume, make sure to update any configurations required by the new version (Check release notes), before mounting it to the new version of the container.
    • Specify your database connection details to point to the old database. For example, using environment variables such as XL_DB_URL.
    • Make sure to set FORCE_UPGRADE to true in order to force upgrade using the -force-upgrades flag.
note

If you are upgrading from Deploy 22.3 to Deploy 23.1 and want to enable caching, replace the deploy-caches.yaml file in the XL_DEPLOY_SERVER_HOME/centralConfiguration location with the deploy-caches.yaml file in this location and set the cache configuration parameters as required. Refer to steps 2 and 3 in the Single node Docker deployments with Caching for details.

Upgrade Single node Deploy deployment

Docker run

After stopping the old Deploy docker container instance, you can start the upgrade process using a new version through a tag, with the docker run command as follows:

docker run -d  \
-e FORCE_UPGRADE=true \
-p 4516:4516 \
-e XL_DB_URL="jdbc:postgresql://PsqlDbHost:5432/repo" \
-e XL_DB_USERNAME=postgres \
-e XL_DB_PASSWORD="password" \
-v ~/XebiaLabs/xl-deploy-server/conf:/opt/xebialabs/xl-deploy-server/conf \
-v ~/XebiaLabs/xl-deploy-server/plugins:/opt/xebialabs/xl-deploy-server/plugins \
--name xl-deploy xebialabs/xl-deploy:9.5.1

This will start the Deploy container, print out the container ID and detect that if there is an older version of Deploy, and then start the upgrade process. You can also find running containers using the docker ps command.

You can stream the logs from the container using docker logs -f <container id>.

Once the containers have started, you can access them at http://localhost:4516/, you might want to wait for a minute for the service to be up and running.

Docker compose

You can also use a docker-compose file to run XLD containers, see the below file for example:

version: "2"
services:
xl-deploy:
image: xebialabs/xl-deploy:24.1.0
container_name: xl-deploy
ports:
- "4516:4516"
volumes:
- ~/XebiaLabs/xl-deploy-server/conf:/opt/xebialabs/xl-deploy-server/conf
- ~/XebiaLabs/xl-deploy-server/hotfix/lib:/opt/xebialabs/xl-deploy-server/hotfix/lib
- ~/XebiaLabs/xl-deploy-server/hotfix/plugins:/opt/xebialabs/xl-deploy-server/hotfix/plugins
environment:
- FORCE_UPGRADE=true \
- XL_DB_URL="jdbc:postgresql://PsqlDbHost:5432/xl-deploy" \
- XL_DB_USERNAME=postgres \
- XL_DB_PASSWORD="password" \

Save the above content to a file named docker-compose.yml in a folder. and run docker-compose up -d from the same folder. At startup, it will detect that there is old version of Deploy then start upgrade.

If you use a different file name, then run docker-compose -f <filename.yaml> up -d

Once the containers have started, you can access them at http://localhost:4516/, you might want to wait for a minute for the service to be up and running