Upgrading Red Hat Developer Hub
Upgrading a Red Hat Developer Hub instance to a later version by using either the Operator or Helm chart
Abstract
Chapter 1. Upgrading the Red Hat Developer Hub Operator
If you use the Operator to deploy your Red Hat Developer Hub instance, then an administrator can use the OpenShift Container Platform web console to upgrade the Operator to a later version.
OpenShift Container Platform is currently supported from version 4.16 to 4.20. See also the Red Hat Developer Hub Life Cycle.
Prerequisites
- You are logged in as an administrator on the OpenShift Container Platform web console.
- You have installed the Red Hat Developer Hub Operator.
- You have configured the appropriate roles and permissions within your project to create or access an application. For more information, see the Red Hat OpenShift Container Platform documentation on Building applications.
Procedure
- In the Administrator perspective of the OpenShift Container Platform web console, click Operators > Installed Operators.
- On the Installed Operators page, click Red Hat Developer Hub Operator.
- On the Red Hat Developer Hub Operator page, click the Subscription tab.
From the Upgrade status field on the Subscription details page, click Upgrade available.
NoteIf there is no upgrade available, the Upgrade status field value is Up to date.
- On the InstallPlan details page, click Preview InstallPlan > Approve.
If you are on the Orchestrator plugin 1.7, you must manually update the plugin configuration after approval to avoid a failed deployment. For more information, see Upgrading the Orchestrator plugin from 1.7 to 1.9.
Verification
- The Upgrade status field value on the Subscription details page is Up to date.
Chapter 2. Upgrading the Red Hat Developer Hub Helm Chart
You can upgrade to a later version of Red Hat Developer Hub in OpenShift Container Platform by using either the web console or the CLI.
OpenShift Container Platform web console
WarningIf you have installed Developer Hub manually using the Helm CLI, the Helm chart release upgrade in the OpenShift Developer Console is going to fail. The failure is due to the limitations when using the OpenShift Container Platform console to upgrade a Helm release that was initially deployed using the Helm CLI. You can bypass this limitation by using the Helm CLI to upgrade. However, if you still want to upgrade using the console, select the Helm Chart version from the drop-down list and select the Developer Hub version you want to upgrade to. Before performing this step, save your
values.yamlconfiguration file in a different location.ImportantYou can upgrade Red Hat Developer Hub directly from any previous version to the latest release without installing intermediate versions. Before upgrading, you must review the release notes for every skipped version to identify breaking changes, deprecations, or required migration steps. For example, if upgrading from version 1.5 to 1.7, check the release notes for both 1.6 and 1.7.
- In the Developer perspective, click Helm to open the Helm Releases tab.
- Click the overflow menu on the Helm release that you want to use and select Upgrade.
- On the Upgrade Helm Release page, select the version of Developer Hub that you want to upgrade to from the chart version drop-down list.
Click Upgrade.
NoteIt might take a few minutes to delete the resources in the older versions and to start the newer versions of the Developer Hub pods.
- Close all open Developer Hub web pages, and log in again to verify that the upgrade was successful.
OpenShift Container Platform CLI
Log in to the OpenShift Container Platform cluster as the cluster administrator and switch to the project or namespace in which Developer Hub was installed.
$ oc login -u <user> -p <password> https://api.<HOSTNAME>:6443 $ oc project my-rhdh-project
For a new version of the Developer Hub Helm chart, run the following upgrade command:
$ helm upgrade -i rhdh -f new-values.yml \ openshift-helm-charts/redhat-developer-hub --version 1.9.3
NoteYou can also provide extra values to the chart by creating a
new-values.ymlfile on your workstation with values that override the attributes in the installed chart or by adding new attributes.
Chapter 3. Upgrade RHDH from 1.8 to 1.9 using the Helm chart
To upgrade the Red Hat Developer Hub RHDH Helm release to 1.9, if you use custom values.yaml files to override specific lists in the default configuration, you must manually update the files to include new mandatory defaults. Because Helm replaces entire lists during an override, custom values can remove required configurations for the Extensions Catalog Index feature. Failure to include these new volume mounts and environment variables prevents the application from initializing or discovering dynamic plugins.
Prerequisites
- You have a running instance of Red Hat Developer Hub 1.8 deployed using the Helm chart.
Your custom
values.yamlfile overrides any of the following affected fields:-
upstream.backstage.extraVolumeMounts -
upstream.backstage.extraVolumes -
upstream.backstage.initContainers
-
Procedure
Manually merge the new default items into your
values.yamlfile to include the following highlighted items within their lists and avoid configuration loss:upstream: backstage: extraVolumeMounts: # TODO: In addition to your custom mounts and the RHDH defaults, ensure this item is present (defined in the default RHDH chart): - name: extensions-catalog mountPath: /extensions extraVolumes: # TODO: In addition to your custom volumes and the RHDH defaults, ensure this item is present (defined in the default RHDH chart): - name: extensions-catalog emptyDir: {} initContainers: # TODO: Ensure the 'install-dynamic-plugins' container includes these environment variables and volume mounts: - name: install-dynamic-plugins env: # TODO: In addition to your custom env vars and the RHDH defaults for the install-dynamic-plugins init container, # ensure the following items are present (defined in the default RHDH chart): - name: CATALOG_INDEX_IMAGE value: '{{ .Values.global.catalogIndex.image.registry }}/{{ .Values.global.catalogIndex.image.repository }}:{{ .Values.global.catalogIndex.image.tag }}' - name: CATALOG_ENTITIES_EXTRACT_DIR value: '/extensions' volumeMounts: # TODO: In addition to your custom volume mounts and the RHDH defaults for the install-dynamic-plugins init container, # ensure the following item is present (defined in the default RHDH chart): - name: extensions-catalog mountPath: /extensions # ... other fields omitted for brevity
To view the full list of default values for 1.9, run the following command:
helm show values redhat-developer-hub --repo https://charts.openshift.io --version 1.9.3
Verification
- Verify that the Red Hat Developer Hub application successfully initializes.