Upgrade Extensions
This section explains how to upgrade extensions.
Before upgrading the extensions, make sure to update the extension repository to fetch the latest versions. You can update the ks-core extension repository using the following command:
bash -c '#!/bin/bash
set -e # Exit immediately if a command exits with a non-zero status
set -o pipefail # Fail the entire pipeline if any command fails
# If CHART_VERSION is not set via environment variable, fetch it from the installed release
if [ -z "$CHART_VERSION" ]; then
CHART_VERSION=$(helm -n kubesphere-system get metadata ks-core -o json | jq -r '.version')
if [[ -z "$CHART_VERSION" || "$CHART_VERSION" == "null" ]]; then
echo "โ Failed to retrieve the Chart version of ks-core. Aborting."
exit 1
fi
fi
# Construct the Chart URL
CHART_URL="https://charts.kubesphere.io/main/ks-core-$CHART_VERSION.tgz"
# If EXTENSION_REPOSITORY_VERSION is not set via environment variable, fetch it from GitHub
if [ -z "$EXTENSION_REPOSITORY_VERSION" ]; then
EXTENSION_REPOSITORY_VERSION=$(curl -s https://api.github.com/repos/kubesphere-extensions/ks-extensions/releases/latest | jq -r '.tag_name')
if [[ -z "$EXTENSION_REPOSITORY_VERSION" || "$EXTENSION_REPOSITORY_VERSION" == "null" ]]; then
echo "โ Failed to retrieve the latest version of ks-extensions. Aborting."
echo "You can manually visit the GitHub releases page to find the latest version: https://github.com/kubesphere-extensions/ks-extensions/releases"
exit 1
fi
fi
# Upgrade ks-core using the retrieved or provided versions
echo "โ
Preparing to upgrade ks-core to version $CHART_VERSION using extension repository version $EXTENSION_REPOSITORY_VERSION"
helm -n kubesphere-system upgrade ks-core "$CHART_URL" \
--set ksExtensionRepository.image.tag="$EXTENSION_REPOSITORY_VERSION" \
--wait --debug'
Prerequisites
You should have the platform-admin role on KubeSphere platform. For more information, refer to Users and Platform Roles.
Steps
Log in to the KubeSphere web console with a user having the platform-admin role.
Click Extensions Center.
Click the name of the installed extension to enter its details page.
Click
below the extension icon and select Upgrade.
In the update dialog, follow the installation process to complete the upgrade.
Feedback
Was this page Helpful?
Receive the latest news, articles and updates from KubeSphere
Thanks for the feedback. If you have a specific question about how to use KubeSphere, ask it on Slack. Open an issue in the GitHub repo if you want to report a problem or suggest an improvement.