Skip to main content

Performing Updates in kURL Clusters

This topic describes how to perform updates in Replicated kURL installations. It includes procedures for updating an application, as well as for updating the versions of Kubernetes, Replicated KOTS, and add-ons in a kURL cluster.

Update an Application

For kURL installations, you can update an application from the Admin Console. You can also set up automatic updates. See Configuring Automatic Updates.

Online Environments

To perform an update from the Admin Console:

  1. In the Admin Console, go to the Version History tab.

  2. Click Check for updates.

    A new upstream version displays in the list of available versions.

    New Version Available

    View a larger version of this image

  3. (Optional) When there are multiple versions of an application, you can compare the changes between them by clicking Diff releases in the right corner.

    You can review changes between any two arbitrary releases by clicking the icon in the header of the release column. Select the two versions to compare, and click Diff releases to show the relative changes between the two releases.

    Diff Releases

    View a larger version of this image

    New Changes

    View a larger version of this image

  4. (Optional) Click the View preflight checks icon to view or re-run the preflight checks.

    Preflight checks

    View a larger version of this image

  5. Return to the Version History tab and click Deploy next to the target version.

Air Gap Environments

To perform an air gap update from the Admin Console:

  1. Download the .airgap bundle for the new application version. Ensure that you can access the downloaded bundle from the environment where the Admin Console is running.

  2. In the Admin Console, go to the Version History tab.

  3. Click Upload a new version.

    A new upstream version displays in the list of available versions.

    New Version Available

  4. (Optional) When there are multiple versions of an application, you can compare the changes between them by clicking Diff releases in the right corner.

    You can review changes between any two arbitrary releases by clicking the icon in the header of the release column. Select the two versions to compare, and click Diff releases to show the relative changes between the two releases.

    Diff Releases New Changes

  5. (Optional) Click the View preflight checks icon to view or re-run the preflight checks.

    Preflight Checks

  6. Return to the Version History tab and click Deploy next to the target version.

Update the kURL Cluster

You can rerun the kURL installation script to update a kURL cluster. For more information about kURL cluster udpates, see About kURL Cluster Updates.

important

The Kubernetes scheduler automatically reschedules Pods to other nodes during maintenance. Any deployments or StatefulSets with a single replica experience downtime while being rescheduled.

Online Environments

To update the kURL cluster in an online environment:

  1. Run the kURL installation script on any primary node in the cluster:

    curl -sSL https://k8s.kurl.sh/APP_SLUG | sudo bash -s ADVANCED_OPTIONS

    Replace:

    • APP_SLUG with the unique slug for the application from your application vendor.

    • ADVANCED_OPTIONS optionally with any flags listed in Advanced Options in the kURL documentation.

      To use no advanced installation options, remove -s ADVANCED_OPTIONS from the command.

      See the following recommendations for advanced options:

      • installer-spec-file: If you used the installer-spec-file flag to pass a patch.yaml file when you installed, you must pass the same patch.yaml file when you upgrade. This prevents the installer from overwriting any configuration from your patch.yaml file and making changes to the add-ons in your cluster. For example: installer-spec-file="./patch.yaml".

      • app-version-label: By default, the script also upgrades your application to the latest version when you run the installation script.

        You can specify a target application version with the app-version-label flag. To avoid upgrading your application version, set the app-version-label flag to the currently installed application version. For example: app-version-label=1.5.0.

  2. (Kubernetes Upgrades Only) If a Kubernetes upgrade is required, the script automatically prints a Drain local node and apply upgrade? prompt. Confirm the prompt to drain the local primary node and apply the Kubernetes upgrade to the control plane.

    The script continues to drain and upgrade nodes sequentially. For each node, the script prints a command that you must run on the node to upgrade Kubernetes. For more information, see Kubernetes Updates above.

Air Gap Environments

For air gap installations, you must load images on each node in the cluster before you can run the installation script to update Kubernetes and any add-ons. This is because upgraded components might have Pods scheduled on any node in the cluster.

To update the kURL cluster in an air gap environment:

  1. On each node in the cluster, download the kURL .tar.gz bundle provided by your software vendor and extract the contents:

    tar -xvzf FILENAME.tar.gz

    Replace FILENAME with the name of the kURL .tar.gz bundle.

    For more information, see Download the kURL Bundle in Downloading Air Gap Bundles.

  2. Run the following KURL script to ensure all required images are available:

    cat tasks.sh | sudo bash -s load-images
    note

    The kURL installation script that you run in the next step also performs a check for required images and prompts you to run the load-images command if any images are missing.

  3. Run the kURL installation script on any primary node in the cluster with the airgap option:

    cat install.sh | sudo bash -s airgap OTHER_ADVANCED_OPTIONS

    Replace OTHER_ADVANCED_OPTIONS optionally with any flags listed in Advanced Options in the kURL documentation.

    See the following recommendations for advanced options:

    • installer-spec-file: If you used the installer-spec-file flag to pass a patch.yaml file when you installed, you must pass the same patch.yaml file when you upgrade. This prevents the installer from overwriting any configuration from your patch.yaml file and making changes to the add-ons in your cluster. For example: installer-spec-file="./patch.yaml".

    • app-version-label: By default, the script also upgrades your application to the latest version when you run the installation script.

      You can specify a target application version with the app-version-label flag. To avoid upgrading your application version, set the app-version-label flag to the currently installed application version. For example: app-version-label=1.5.0.

  4. (Kubernetes Upgrades Only) If a Kubernetes upgrade is required, the script automatically prints a Drain local node and apply upgrade? prompt. Confirm the prompt to drain the local primary node and apply the Kubernetes upgrade to the control plane.

    The script continues to drain and upgrade nodes sequentially. For each node, the script prints a command that you must run on the node to upgrade Kubernetes. For more information, see Kubernetes Updates above.

    note

    If Kubernetes must be upgraded by more than one minor version, the script automatically searches for the required Kubernetes assets in the /var/lib/kurl/assets/ directory. If the assets are not available, the script prints a command to download the assets as a tar.gz package. Download and provide the absolute path to the package when prompted to continue with the upgrade.