Upgrading the operator by running a script
To upgrade the operator, a cluster administrator user can run a script to set up the cluster. The administrator needs permission to apply or created custom resource definitions (CRD's) and create namespaces. The deployment script will detect the existing installation version and method and provide a fresh install path for missing operators or upgrade existing.
Before you begin
The upgrade_deployment.py script uses the following utility tools and needs them to be installed on your client machine:
- Kubernetes CLI
- Python
- Helm CLI
ibm-content-cortex-containersrepository from GitHub
About this task
OCP and
CNCF platforms, deployments will be migrated to a Helm chart install.
When you run the script the prerequisites validation for the script checks whether the required utility tools like Helm CLI and if the connection to the cluster is successful. It also checks if the required descriptor files exist. If the prerequisites validation fails, the script flags the missing tools and files. The script will detect the current installation of the operators, either being at the correct version, available for fresh install or requiring an upgrade. If an OLM or Yaml based deployment is detected, on upgrade these resources will be cleaned and a Helm based install will proceed. It also gives you the option to install the IBM Content Cortex AI Services operator. For more information about the AI Services operator, see AI Services on container platforms.
python3 deploy_operator.py --help
Usage: deploy_operator.py [OPTIONS]
Content Cortex Operator Deployment CLI.
Options:
--version Show version and exit.
--install-completion Install completion for the current shell.
--show-completion Show completion for the current shell, to copy it or customize the installation.
--help Show this message and exit.
Customization and Utils:
--silent --no-silent Enable Silent Install (no prompts). [default: no-silent]
--verbose --no-verbose Enable verbose logging. [default: no-verbose]
--dryrun --no-dryrun Perform a dry run [default: no-dryrun]
--validate --no-validate Disable validation of entitlement key or private registry. [default: validate]
--force --no-force Force redeployment even if operators are already at target version. [default: no-force]
Deployment Method:
--use-olm --no-use-olm Use OLM (Operator Lifecycle Manager) for deployment instead of Helm. [default: no-use-olm]
--helm-chart-source TEXT Helm chart source: 'github' (default - downloads from GitHub), 'packaged' (local files), 'local' (unpacked charts), 'public' (Helm repo), or 'url'. [default: github]
You can run the script interactively, or supply the configuration file beforehand and
run the script as a silent deployment. python3 deploy_operator.pypython3 deploy_operator.py --silent