From 57a94add68824f657938bdf3c80c3db2dbe94449 Mon Sep 17 00:00:00 2001 From: Ekaterina Kazakova <41469478+eromanova@users.noreply.github.com> Date: Tue, 26 Nov 2024 14:41:04 +0400 Subject: [PATCH] Add 2A upgrade documentation (#41) Closes: https://github.com/Mirantis/hmc/issues/399 --- docs/usage/2a-upgrade.md | 52 ++++++++++++++++++++++++++++++++++++++++ mkdocs.yml | 1 + 2 files changed, 53 insertions(+) create mode 100644 docs/usage/2a-upgrade.md diff --git a/docs/usage/2a-upgrade.md b/docs/usage/2a-upgrade.md new file mode 100644 index 0000000..53269a8 --- /dev/null +++ b/docs/usage/2a-upgrade.md @@ -0,0 +1,52 @@ +# Upgrading 2A to the newer version + +> NOTE: To upgrade 2A the user must have `Global Admin` role. +> For the detailed information about 2A RBAC, refer to the [RBAC documentation](../rbac/roles.md). + +Follow the steps below to update 2A to a newer version: + +**Step 1. Create a New `Release` Object** + +Create a `Release` object in the management cluster for the desired version. For example, to create +a `Release` for version `v0.0.4`, run the following command: + +```shell +VERSION=v0.0.4 +kubectl create -f https://github.com/Mirantis/hmc/releases/download/${VERSION}/release.yaml +``` + +**Step 2. Update the `Management` Object with the New `Release`** + +- List available `Releases`: + +To view all available `Releases`, run: + +```shell +kubectl get releases +``` + +Example output: + +```shell +NAME AGE +hmc-0-0-3 71m +hmc-0-0-4 65m +``` + +- Patch the `Management` Object with the New `Release` Name: + +Update the `spec.release` field in the `Management` object to point to the new release. Replace `hmc-0-0-4` with +the name of your new release: + +```shell +RELEASE_NAME=hmc-0-0-4 +kubectl patch management.hmc hmc --patch "{\"spec\":{\"release\":\"${RELEASE_NAME}\"}}" --type=merge +``` + +**Step 3. Verify the Upgrade** + +Check the status of the `Management` object to monitor the readiness of the components: + +```shell +kubectl get management.hmc hmc -o=jsonpath={.status} | jq +``` diff --git a/mkdocs.yml b/mkdocs.yml index 35f221c..d04fc93 100644 --- a/mkdocs.yml +++ b/mkdocs.yml @@ -79,6 +79,7 @@ nav: - Air-gapped Installation Guide: usage/airgap.md - Create Managed Cluster: usage/create-managed-cluster.md - Cluster Updates: usage/cluster-update.md + - 2A Upgrade: usage/2a-upgrade.md - Templates: - Overview: template/main.md - BYO Templates: template/byo-templates.md