DevOps Automation

 View Only

UrbanCode Deploy running as a container - Upgrade & Troubleshooting

By Laurel Dickson-Bull posted Mon July 11, 2022 03:16 PM

  

If you are running UrbanCode Deploy (now DevOps Deploy) as a container – UCD containers are certified by IBM – you will want this information about upgrading. We included also a short Troubleshooting section for your reference.

Upgrading the UrbanCode Deploy Server

Prepare a backup

Follow these general backup steps:

  • Cancel or wait for all running deployment processes to complete, then scale the UrbanCode Deploy server statefulset to 0.
  • Back up the database. For example, export the schema to a file.
  • Back up the appdata persistent volume.
  • Scale the UrbanCode Deploy server statefulset to 1.

Upgrade

  • Perform a helm upgrade on the UrbanCode Deploy server.
  • Verify that your deployment processes operate correctly after the upgrade. If any problems are encountered with the new version, roll back to the previous version.

 

Roll back the upgrade

Follow these general steps to roll back the upgrade:

  • Cancel or wait for all running deployment processes to complete, then scale the UrbanCode Deploy server statefulset to 0.
  • Restore the database. For example, drop the schema and import the schema from the backup file.
  • Restore the appdata directory backup to the persistent volume.
  • Perform a helm rollback to the previous revision of the UrbanCode Deploy server.
  • Scale the UrbanCode Deploy server to 1 and verify that your deployment processes operate correctly after the rollback.

 

Upgrading UrbanCode Deploy Agent

Prepare a backup

Follow these general backup steps:

  • Cancel or wait for all running deployment processes to complete, then scale the UrbanCode Deploy agent statefulset to 0.
  • Back up the conf persistent volume.
  • Scale the UrbanCode Deploy agent statefulset to 1.

  Upgrade 

  • Perform a helm upgrade on the UrbanCode Deploy agent.
  • Verify that your deployment processes operate correctly after the upgrade. If any problems are encountered with the new version, roll back to the previous version.

 

Roll back the upgrade

Follow these general steps to roll back the upgrade:

 

  • Cancel or wait for all running deployment processes to complete, then scale the UrbanCode Deploy agent statefulset to 0.
  • Restore the conf directory backup to the persistent volume.
  • Perform a helm rollback to the previous revision of the UrbanCode Deploy agent.
  • Scale the UrbanCode Deploy agent to 1 and verify that your deployment processes operate correctly after the rollback.

Upgrading UrbanCode Deploy Agent Relay

Prepare a backup

Follow these general backup steps:

  • Cancel or wait for all running deployment processes to complete, then scale the UrbanCode Deploy agent relay statefulset to 0.
  • Back up the conf persistent volume.
  • Scale the UrbanCode Deploy agent relay statefulset to 1

  

Upgrade

  • Perform a helm upgrade on the UrbanCode Deploy agent relay.
  • Verify that your deployment processes operate correctly after the upgrade. If any problems are encountered with the new version, roll back to the previous version.

 

Roll back the upgrade

Follow these general steps to roll back the upgrade:

 

  • Cancel or wait for all running deployment processes to complete, then scale the UrbanCode Deploy agent relay statefulset to 0.
  • Restore the conf directory backup to the persistent volume.
  • Perform a helm rollback to the previous revision of the UrbanCode Deploy agent relay.
  • Scale the UrbanCode Deploy agent relay to 1 and verify that your deployment processes operate correctly after the rollback.

 Troubleshooting

 

Did something go wrong when running UrbanCode Deploy as a container?  This page contains information to help with debugging issues you may see when running the UrbanCode Deploy server as a container.

 

Checking the init Container

 

When you install a release of UrbanCode Deploy using the provided helm chart, two containers are created.  The first is named init and performs some initialization steps, including initializing your database if needed.

 

To get logging information for the init container, enter the command:

 

>kubectl logs [pod name] -c init

 

Part of the initialization process involves connecting to the database and pulling the UrbanCode Deploy version information from the database.  If you are installing a new release of UrbanCode Deploy with a new database, the database will not be initialized and not yet contain an UrbanCode Deploy version.  In this case, expected to see a message such as:

 

>[Error] Table DS_DATABASE_VERSION does not exist.

 

After the error/warning message, you should see a message indicating the database has been initialized.  It may take some time for the database to initialize.

 

 

If connecting to a previously initialized database, the version of UrbanCode Deploy used to initialize the database should be displayed.

 

Checking the ibm-ucd-prod Container

 

Once the init container has completed, the UrbanCode Deploy container should start. Installation and setup logs may be viewed by running:

 

>kubectl logs [pod name] -c ibm-ucd-prod

 

Once the container is running, you may execute commands inside the container using:

 

>kubectl exec -it [pod name] -- /bin/bash

 

The UrbanCode Deploy server is installed under /opt/ibm-ucd/server. You may navigate to that directory and explore settings and log files as you do with on-prem UrbanCode Deploy.

 

 

 


#DevOps


#UrbanCodeDeploy
#containers

0 comments
14 views

Permalink