XRAY: Migration of Xray from VM to Helm Installation

AuthorFullName__c
David Kahan
articleNumber
000006826
FirstPublishedDate
2026-01-13T13:44:24Z
lastModifiedDate
2026-01-13

XRAY: Migration of Xray from VM to Helm Installation

Introduction 

This article provides the prerequisites, recommendations, and necessary steps for migrating Xray from a virtual machine (VM) to a Helm installation.

Prerequisites:
  1. Artifactory must be fully migrated from the VM to a Helm installation. A Helm installation of Xray cannot operate with an Artifactory VM installation. Please refer to the guide on migrating Artifactory installation method.
  2. Confirm that the Xray system requirements for the Helm installation setup are met.
  3. The migration must only occur between the same version of Xray.
  4. Ensure that the versions of Artifactory on both the VM and Helm installations are identical to prevent potential compatibility issues.

Recommendations:
  • It is advisable to execute the migration steps in a staging environment before applying them to production environments.
  • Create a snapshot or backup of the current Xray and PostgreSQL database to facilitate restoration if necessary.

Migration Steps:
  1. Follow steps 1-5 for installing Xray on Helm.
  2. Stop the Xray service on the VM installation.
  3. Copy the master key from the VM installation, located at $XRAY_HOME/etc/security/master.key.
  4. Create a secret from the master key for the Helm installation and reference the secret in the values.yaml as follows:
    global:
       masterKeySecretName: master-key-secret
  5. Retrieve the connection details and credentials for the Xray PostgreSQL database from the system.yaml file found under $XRAY_HOME/var/etc and add them to the values.yaml, either directly or by referencing them as a secret. These details should be included in the database  section in the values.yaml.
  6. Copy the system.yaml content from the Xray VM and place it under extraSystemYaml in the values.yaml. Ensure that the following configurations are edited:
    1. Remove the database details, as these have been relocated to the values.yaml in step 5.
    2. Remove the shared.node.ip configuration, as it is not needed in the Helm installation.
  7. Execute the Helm installation with the chart version that matches the Xray version in use on the VM installation:
    helm upgrade --install xray --namespace xray -f values.yaml --version <YOUR_DESIRED_XRAY_CHART_VERSION>

  8. Verify in the UI that the Xray service is up and running.