Install or Upgrade Digital.ai Release on an Air-gapped Environment
You can install Release in an air-gapped environment disconnected from the public internet. This topic provides information about installing and upgrading Release in such environments using a Minikube cluster and a custom image registry. For other Kubernetes platforms, steps are similar to the ones listed here for Minikube as long as the custom image registry contains all the required images.
Note: The Amazon Elastic Container Registry (ECR) does not support having all necessary images in a single repository and hence, cannot be used as a custom image registry.
Prerequisites
- Read and understand the Plan Your Installation or Upgrade
- Read and understand the XL CLI's xl kube command
- A computer that runs Windows, macOS, or Linux to install and run the kubectl and other CLIs
- XL CLI 24.3.0 or later
- kubectl
- Docker
Installing Deploy in an Air-gapped Cluster Environment
Here's a detailed step-by-step.
Step 1: Download the appropriate blueprint version
- Run the following command:
xl kube help
This command returns the following message:
Install, upgrade or clean Digital.ai Deploy or Digital.ai Release on a Kubernetes cluster using operator technology.
Installation blueprint files are used from https://dist.xebialabs.com/public/xl-op-blueprints/24.3.x/.
You need to have kubectl installed and configured for the target Kubernetes cluster.
The xl kube
command will search for blueprints from this location.
Note: The 24.3.x in the URL refers to the appropriate version of xl-op-blueprints. Use the specific version required for your installation.
- Download all the files from that location and place them in the server directory where you will execute the
xl kube
command.
Tip: Download the zipped version of the xl-op-blueprints from this location
- Unzip it to the server where you will execute the
xl kube
command.
Step 2: Add the necessary operator-related images to your image registry
When you run a Kubernetes cluster in an air-gapped environment, it's impossible to download images from public registries such as docker.io, gcr.io, or quay.io. Therefore, you need to set up an image registry also called as custom image registry. This should be either public (not password protected) or private (password protected), that is accessible to the Kubernetes cluster. This can be done by creating a private image repository on your cloud provider or a local image registry.
- Get Prerequisite Images
Based on your installation plan, push the images to your image repository.
For the list of prerequisite images check Setup Custom Image Registry
- Push the images to an internally accessible Docker registry.
To ensure that the required images are available in an air-gapped Kubernetes cluster, you must pull them first on a Bastion instance with public internet connectivity, tag them, and push them to the previously created Docker image registry that's internally accessible. Once this is done, your Kubernetes cluster can pull the required images from the Docker registry.
For example:
In the Docker registry (myrepo_host
), run the following command to push the Docker image (xl-release
) to the repository (myrepo
):
Note: Replace <version>
with the version of Release you are trying to install.
docker pull docker.io/xebialabs/xl-release:<version>
docker tag docker.io/xebialabs/xl-release:<version> myrepo_host/myrepo/xl-release:<version>
docker push myrepo_host/myrepo/xl-release:<version>
Note: Ensure that you are logged in to the Docker registry before pushing the images.
- Create a secret for private image registry with password protection.
Note: It's required only when you use a private image registry.
Run the following command:
kubectl create secret docker-registry regcred \
--docker-server=myrepo_host \
--docker-username=<reg-user> \
--docker-password=<reg-password> \
-n digitalai
This example creates a secret called regcred
which can be used as pull secrets required for pulling images from a private image registry.