Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -17,18 +17,18 @@ In a partially disconnected environment, the cluster cannot access external regi

. In a terminal, download and extract the Helm chart by running the following commands:
+
[source,terminal,subs="attributes+"]
[source,terminal,subs="+attributes,+quotes"]
----
helm repo add _<helm_chart_repo_name>_ https://charts.openshift.io/
helm repo update
helm pull _<helm_chart_repo_name>_/redhat-developer-hub --version _<rhdh_version>_
helm show values _<helm_chart_repo_name>_/redhat-developer-hub --version _<rhdh_version>_ > values.default.yaml
----
+
where
where:

_<helm_chart_repo_name>_ :: Specifies the name of the Helm chart repository, for example, `openshift-helm-charts`.
_<rhdh_version>_ :: Specifies the {product} version that you want to use, for example, `{product-chart-version}`.
_<helm_chart_repo_name>_ :: Enter the name of the Helm chart repository, for example, `openshift-helm-charts`.
_<rhdh_version>_ :: Enter the {product} version that you want to use, for example, `{product-chart-version}`.
+
. Use `yq` to extract the image digests by running the following commands:
+
Expand Down
59 changes: 28 additions & 31 deletions modules/installation/proc-install-rhdh-helm-airgapped-full.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -6,38 +6,36 @@ If your network has access to the registry through a bastion host, you can use t
.Prerequisites

* You have set up your workstation.
** You have access to the registry.redhat.io.
** You have an account in https://developers.redhat.com/[{rhdeveloper-name}] portal.
** You have access to the charts.openshift.io Helm chart repository.
** You have installed the {openshift-cli} on your workstation.
* {ocp-docs-link}/html-single/disconnected_environments/index#about-installing-oc-mirror-v2[You have installed the oc-mirror OpenShift CLI plugin].
** You have an account in https://developers.redhat.com/[{rhdeveloper-name}] portal.
** You have set up your intermediary host.
** Your host has access to the disconnected cluster and to the target mirror registry, for example, the {ocp-brand-name} image registry. For more information about exposing the {ocp-short} image registry, see {ocp-docs-link}/html-single/registry/index#securing-exposing-registry[Exposing the registry].
** {ocp-docs-link}/html-single/disconnected_environments/index#about-installing-oc-mirror-v2[You have installed the oc-mirror OpenShift CLI plugin].
** You have installed the {ocp-docs-link}/html-single/disconnected_environments/index#installation-oc-mirror-installing-plugin_about-installing-oc-mirror-v2[`oc-mirror`] tool, with a version corresponding to the version of your {ocp-short} cluster.
* You have set up your intermediary host.
** Your host has access to the link:https://registry.redhat.io[{company-name} Ecosystem Catalog].
** Your host has access to image registry on the destination host.
See {ocp-docs-link}/html-single/registry/index#securing-exposing-registry[Exposing the registry].
* You have set up your destination host.
** You have installed {ocp-brand-name} {ocp-version-min} or later.
** You have installed the {openshift-cli} on your workstation.
* Make sure that your system meets the minimum sizing requirements. See {about-book-link}#rhdh-sizing_about-rhdh[Sizing requirements for {product}].
** Your system meets the minimum sizing requirements. See {about-book-link}#rhdh-sizing_about-rhdh[Sizing requirements for {product}].

.Procedure
. Create an `ImageSetConfiguration` file to specify the resources that you want to mirror. For example:
+
[source,terminal,subs="+quotes"]
[source,yaml,subs="+attributes,+quotes"]
----
apiVersion: mirror.openshift.io/v1alpha2
kind: ImageSetConfiguration
mirror:
helm:
repositories:
- name: _<repository_name>_ (1)
url: _<repository_url>_ (2)
- name: openshift-charts
url: https://charts.openshift.io
charts:
- name: _<chart_name>_ (3)
version: "_<rhdh_version>_" (4)
- name: redhat-developer-hub
version: "{product-version}"
----
<1> The name of the repository that you want to mirror, for example, `openshift-charts`.
<2> The URL for the repository that you want to mirror, for example, `https://charts.openshift.io`.
<3> The name of the Helm chart that you want to mirror, for example, `redhat-developer-hub`.
<4> The version of {product} that you want to use, for example, `{product-version}`
where:
`version: "{product-version}"`:: Enter the {product} version to mirror.

. Mirror the resources specified in the `ImageSetConfiguration.yaml` file by running the `oc-mirror` command. For example:
+
Expand All @@ -49,19 +47,18 @@ oc-mirror --config=_<mirror_config_directory>_/ImageSetConfiguration.yaml _<mirr
--
where:

`<mirror_config_directory>` :: Specifies the location of your image set configuration file on your system, for example, `.user`.
`<mirror_config_directory>` :: Enter the location of your image set configuration file on your system, for example, `.user`.

`<mirror_configuration_file>` :: Specifies the name of your mirror configuration yaml file, for example, `mirror-config.yaml`

`<mirror_archive_directory>` :: Specifies the location of your directory where the mirror archive will be created, for example, `pass:[file://.user]`.
`<mirror_archive_directory>` :: Enter the location of your directory where the mirror archive will be created, for example, `pass:[file://.user]`.
--
+
[NOTE]
====
Running the `oc-mirror` command generates a local workspace containing the mirror archive file, the Helm chart, and a `ImageContentSourcePolicy` (ICSP) manifest. The ICSP manifest contains an `imageContentSourcePolicy.yaml` file that you must apply against the cluster in a later step.
====
+
.Example output
Example output:
+
[source,terminal,subs="+quotes"]
----
Creating archive /path/to/mirror-archive/mirror_seq1_000000.tar
Expand All @@ -83,9 +80,9 @@ oc-mirror --from _<mirror-archive-file>_ _<target-registry>_
--
where:

`<mirror_archive_file>` :: Specifies the name of the file containing the resources that you want to mirror, for example,`mirror_seq1_0000.tar`.
`<mirror_archive_file>` :: Enter the name of the file containing the resources that you want to mirror, for example,`mirror_seq1_0000.tar`.

`<target_registry>` :: Specifies the name of the target registry that you want to push the mirrored images to, for example, `docker://registry.localhost:5000`.
`<target_registry>` :: Enter the name of the target registry that you want to push the mirrored images to, for example, `docker://registry.localhost:5000`.
--
+
.Example output
Expand Down Expand Up @@ -121,9 +118,9 @@ oc apply -f _<workspace_directory>_/_<results_directory>_/ImageContentSourcePoli
--
where:

`<workspace-directory>` :: Specifies the name of your workspace directory, for example, `oc-mirror-workspace`.
`<workspace-directory>` :: Enter the name of your workspace directory, for example, `oc-mirror-workspace`.

`<results-directory>` :: Specifies the name of your results directory, for example, `results-1738070846`.
`<results-directory>` :: Enter the name of your results directory, for example, `results-1738070846`.
--
. In your air-gapped environment, deploy the Helm chart to the namespace that you want to use by running the `helm install` command with `namespace` and `set` options. For example:
+
Expand All @@ -138,13 +135,13 @@ helm install _<rhdh_instance>_ _<workspace_directory>_/_<results_directory>_/cha
--
where:

`<rhdh_instance>` :: Specifies the name of your {product} instance, for example, `my-rhdh`.
`<rhdh_instance>` :: Enter the name of your {product} instance, for example, `{my-product-namespace}`.

`<workspace_directory>` :: Specifies the name of your workspace directory, for example, `oc-mirror-workspace`.
`<workspace_directory>` :: Enter the name of your workspace directory, for example, `oc-mirror-workspace`.

`<results_directory>` :: Specifies the name of your results directory, for example, `results-1738070846`.
`<results_directory>` :: Enter the name of your results directory, for example, `results-1738070846`.

`<archive_file>` :: Specifies the name of the archive file containing the resources that you want to mirror, for example, `redhat-developer-hub-1.4.1.tgz`.
`<archive_file>` :: Enter the name of the archive file containing the resources that you want to mirror, for example, `redhat-developer-hub-1.4.1.tgz`.

`<your_namespace>` :: Specifies the namespace that you want to deploy the Helm chart to, for example, `{my-product-namespace}`.
`<your_namespace>` :: Enter the namespace that you want to deploy the Helm chart to, for example, `{my-product-namespace}`.
--
17 changes: 7 additions & 10 deletions modules/installation/proc-install-rhdh-helm-airgapped-partial.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ If your network has access to the `registry.redhat.io` registry and the `charts.
* You have access to a mirror registry that can be reached from the disconnected cluster, for example, the {ocp-short} image registry. For more information about exposing the {ocp-short} image registry, see {ocp-docs-link}/html-single/registry/index#securing-exposing-registry[Exposing the registry].
* You are logged in to your target mirror registry and have permissions to push images to it. For more information, see {ocp-docs-link}/html-single/disconnected_environments/index#installation-adding-registry-pull-secret_about-installing-oc-mirror-v2[Configuring credentials that allow images to be mirrored].
* You have installed the {openshift-cli} on your workstation.
* {ocp-docs-link}/html-single/disconnected_environments/index#about-installing-oc-mirror-v2[You have installed the oc-mirror OpenShift CLI plugin].
* Recommended on {ocp-short}: You have installed the {ocp-docs-link}/html-single/disconnected_environments/index#installation-oc-mirror-installing-plugin_about-installing-oc-mirror-v2[`oc-mirror`] tool, with a version corresponding to the version of your {ocp-short} cluster.
* You have an account in https://developers.redhat.com/[{rhdeveloper-name}] portal.
* Make sure that your system meets the minimum sizing requirements. See {about-book-link}#rhdh-sizing_about-rhdh[Sizing requirements for {product}].

Expand All @@ -27,23 +27,20 @@ oc login -u <user> -p <password> https://api.<hostname>:6443
. Create an `ImageSetConfiguration.yaml` file.
. In your `ImageSetConfiguration.yaml` file, specify the resources that you want to mirror. For example:
+
[source,terminal,subs="+quotes"]
[source,yaml,subs="+attributes,+quotes"]
----
apiVersion: mirror.openshift.io/v1alpha2
kind: ImageSetConfiguration
mirror:
helm:
repositories:
- name: _<repository_name>_ (1)
url: _<repository_url>_ (2)
- name: openshift-charts
url: https://charts.openshift.io
charts:
- name: _<chart_name>_ (3)
version: "_<rhdh_version>_" (4)
- name: redhat-developer-hub
version: "{product-version}"
----
<1> The name of the repository containing the Helm chart that you want to mirror, for example, `openshift-charts`.
<2> The URL for the repository containing the Helm chart that you want to mirror, for example, `https://charts.openshift.io`.
<3> The name of the Helm chart containing the images that you want to mirror, for example, `redhat-developer-hub`.
<4> The {product} version that you want to use, for example, `{product-version}`
`version: "{product-version}"`:: Enter the {product} version to mirror.

. Mirror the resources specified in the image set configuration file directly to the target registry by running the `oc-mirror` command. For example:
+
Expand Down
31 changes: 17 additions & 14 deletions modules/installation/proc-install-rhdh-operator-airgapped-full.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -15,27 +15,29 @@ If your network has access to the registry through a bastion host, you can use t
* You have installed `umoci` CLI tool.
* You have an active `oc registry`, `podman`, or `skopeo` session to the `registry.redhat.io` {company-name} Ecosystem Catalog. For more information, see link:link:https://access.redhat.com/articles/RegistryAuthentication[{company-name} Container Registry Authentication].
* You have installed the `opm` CLI tool. For more information, see {ocp-docs-link}/html/cli_tools/opm-cli#olm-about-opm_cli-opm-install[Installing the opm CLI].
* Recommended on {ocp-short}: You have installed the {ocp-docs-link}/html-single/disconnected_environments/index#installation-oc-mirror-installing-plugin_about-installing-oc-mirror-v2[`oc-mirror`] tool, with a version corresponding to the version of your {ocp-short} cluster.
* Make sure that your system meets the minimum sizing requirements. See {about-book-link}#rhdh-sizing_about-rhdh[Sizing requirements for {product}].

.Procedure
. Download the mirroring script to disk by running the following command:
+
[source,terminal,subs="attributes+"]
[source,terminal,subs="+attributes,+quotes"]
----
curl -sSLO https://raw.githubusercontent.com/redhat-developer/rhdh-operator/refs/heads/release-{product-version}/.rhdh/scripts/prepare-restricted-environment.sh
----
+
. Run the mirroring script by using the `bash` command with the appropriate set of options:
+
[source,terminal,subs="attributes+"]
[source,terminal,subs="+attributes,+quotes"]
----
bash prepare-restricted-environment.sh
--filter-versions "{product-version}"
--to-dir _<my_pulled_image_location>_ <1>
[--use-oc-mirror true] <2>
--to-dir _<my_pulled_image_location>_
[--use-oc-mirror true]
----
<1> Specifies the absolute path to a directory where you want to pull all of the necessary images with the `--to-dir` option, for example, `/home/user/rhdh-operator-mirror-dir`.
<2> (Optional) Uses the `oc-mirror` {ocp-short} CLI plugin to mirror images.
where:
`--to-dir _<my_pulled_image_location>_`:: Enter the absolute path to a directory where you want to pull all of the necessary images, for example, `/home/user/rhdh-operator-mirror-dir`.
`--use-oc-mirror true`:: (Recommended on {ocp-short}) Use the `oc-mirror` {ocp-short} CLI plugin to mirror images.
+
[NOTE]
====
Expand All @@ -47,15 +49,16 @@ The script can take several minutes to complete as it copies multiple images to
+
[source,terminal,subs="+quotes,+attributes"]
----
bash _<my_pulled_image_location>_/install.sh <1>
--from-dir _<my_pulled_image_location>_ <2>
[--to-registry _<my.registry.example.com>_] <3>
[--use-oc-mirror true] <4>
bash _<my_pulled_image_location>_/install.sh
--from-dir _<my_pulled_image_location>_
[--to-registry _<my.registry.example.com>_]
[--use-oc-mirror true]
----
<1> The downloaded image and the absolute path to the directory where it is stored on your system.
<2> Specifies the directory where you want to pull all of the necessary images with the `--to-dir` option.
<3> Specifies the URL for the target mirror registry where you want to mirror the images.
<4> (Optional) Uses the `oc-mirror` {ocp-short} CLI plugin to mirror images.
where:
`_<my_pulled_image_location>_/install.sh`:: Enter the downloaded installation script and the absolute path to the directory where it is stored on your system.
`--from-dir _<my_pulled_image_location>_`:: Enter the directory where you want to pull all of the necessary images.
`--to-registry`:: (Optional) Enter the URL for the target mirror registry where you want to mirror the images.
`--use-oc-mirror true`:: Recommended on {ocp-short}: Use the `oc-mirror` {ocp-short} CLI plugin to mirror images.
+
[IMPORTANT]
====
Expand Down
Loading