This documentation is for a release that is no longer maintained
See documentation for the latest supported version.Chapter 3. Air-gapped environment
An air-gapped environment, also known as an air-gapped network or isolated network, ensures security by physically segregating the system or network. This isolation is established to prevent unauthorized access, data transfer, or communication between the air-gapped system and external sources.
You can install the Red Hat Developer Hub in an air-gapped environment to ensure security and meet specific regulatory requirements.
3.1. Installing Red Hat Developer Hub in an air-gapped environment Copy linkLink copied to clipboard!
To install the Developer Hub in an air-gapped environment, you must have access to the registry.redhat.io
and the registry for the air-gapped environment.
Prerequisites
- You have installed an Openshift Container Platform (OCP) 4.10 or later.
-
You have access to the
registry.redhat.io
. - You have access to the OpenShift image registry of your cluster. For more information about exposing the OpenShift image registry, see Exposing the registry in OpenShift documentation.
-
You have installed the
oc
command line tool on your workstation. -
You have installed the
podman
command line tools on your workstation. - You you have an account in Red Hat Developer portal.
Procedure
Log in to the OCP using
oc
:oc login -u <user> -p <password> https://api.<HOSTNAME>:6443
oc login -u <user> -p <password> https://api.<HOSTNAME>:6443
Copy to Clipboard Copied! Toggle word wrap Toggle overflow Log in to the OCP image registry using
podman
:podman login -u kubeadmin -p $(oc whoami -t) default-route-openshift-image-registry.<HOSTNAME>
podman login -u kubeadmin -p $(oc whoami -t) default-route-openshift-image-registry.<HOSTNAME>
Copy to Clipboard Copied! Toggle word wrap Toggle overflow NoteYou can use the following commands to get the full host name of the OpenShift image registry and than use the host name in a command to log in:
REGISTRY_HOST=$(oc get route default-route -n openshift-image-registry --template='{{ .spec.host }}') podman login -u kubeadmin -p $(oc whoami -t) $REGISTRY_HOST
REGISTRY_HOST=$(oc get route default-route -n openshift-image-registry --template='{{ .spec.host }}') podman login -u kubeadmin -p $(oc whoami -t) $REGISTRY_HOST
Copy to Clipboard Copied! Toggle word wrap Toggle overflow Log in to the
registry.redhat.io
inpodman
using the following command:podman login registry.redhat.io
podman login registry.redhat.io
Copy to Clipboard Copied! Toggle word wrap Toggle overflow For more information about registry authentication, see Red Hat Container Registry Authentication.
Pull Developer Hub and PostgreSQL images from Red Hat Image registry to your workstation:
podman pull <DEVELOPERHUBIMAGE> podman pull registry.redhat.io/rhel9/postgresql-15:latest
podman pull <DEVELOPERHUBIMAGE> podman pull registry.redhat.io/rhel9/postgresql-15:latest
Copy to Clipboard Copied! Toggle word wrap Toggle overflow Push both images to the internal OCP registry.
For more information about pushing images directly to OCP registry, see How do I push an Image directly into the OpenShift 4 registry.
podman push --remove-signatures registry.redhat.io/rhel9/postgresql-15:latest default-route-openshift-image-registry.<hostname>/<yourProject>/postgresql-15:latest
podman push --remove-signatures registry.redhat.io/rhel9/postgresql-15:latest default-route-openshift-image-registry.<hostname>/<yourProject>/postgresql-15:latest
Copy to Clipboard Copied! Toggle word wrap Toggle overflow TipIf an x509 error occurs, ensure you install the CA certificate used for OpenShift routes on your system.
Optionally, you can append
--tls-verify=false
to thepodman
push command, note that this approach is not recommended.Use the following command to verify that both images are present in the internal OCP registry:
oc get imagestream -n <projectName>
oc get imagestream -n <projectName>
Copy to Clipboard Copied! Toggle word wrap Toggle overflow Enable local image lookup for both images using the following commands:
oc set image-lookup postgresql-15 oc set image-lookup rhdh-hub-rhel9
oc set image-lookup postgresql-15 oc set image-lookup rhdh-hub-rhel9
Copy to Clipboard Copied! Toggle word wrap Toggle overflow Go to YAML view and update the
image
section forbackstage
andpostgresql
using the following values:Example values for Developer Hub image
Copy to Clipboard Copied! Toggle word wrap Toggle overflow Example values for PostgreSQL image
Copy to Clipboard Copied! Toggle word wrap Toggle overflow - Install the Red Hat Developer Hub using Helm Chart. For more information about installing Developer Hub, see Chapter 2, Installing Red Hat Developer Hub using Helm Chart.