Skip to content

Commit ced1ac3

Browse files
authored
Merge pull request #31968 from mburke5678/BZ-1889413
Only global pull secrets can be configured in clusters where ImageContentSourcePolicy is set
2 parents d584deb + 5581340 commit ced1ac3

7 files changed

+37
-1
lines changed

modules/builds-image-source.adoc

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -39,6 +39,11 @@ source:
3939
<4> The directory relative to the build root where the build process can access the file.
4040
<5> The location of the file to be copied out of the referenced image.
4141
<6> An optional secret provided if credentials are needed to access the input image.
42+
+
43+
[NOTE]
44+
====
45+
If your cluster uses an `ImageContentSourcePolicy` object to configure repository mirroring, you can use only global pull secrets for mirrored registries. You cannot add a pull secret to a project.
46+
====
4247

4348
Optionally, if an input image requires a pull secret, you can link the pull secret to the service account used by the build. By default, builds use the `builder` service account. The pull secret is automatically added to the build if the secret contains a credential that matches the repository hosting the input image. To link a pull secret to the service account used by the build, run:
4449

modules/images-configuration-registry-mirror.adoc

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,10 +30,16 @@ By pulling container images needed by {product-title} and then bringing those im
3030
Even if you don't configure mirroring during {product-title} installation, you can do so later using the `ImageContentSourcePolicy` object.
3131

3232
The following procedure provides a post-installation mirror configuration, where you create an `ImageContentSourcePolicy` object that identifies:
33-
33+
--
3434
* The source of the container image repository you want to mirror.
3535
* A separate entry for each mirror repository you want to offer the content
3636
requested from the source repository.
37+
--
38+
39+
[NOTE]
40+
====
41+
You can only configure global pull secrets for clusters that have an `ImageContentSourcePolicy` object. You cannot add a pull secret to a project.
42+
====
3743

3844
.Prerequisites
3945
* Access to the cluster as a user with the `cluster-admin` role.

modules/olm-mirroring-catalog.adoc

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -175,6 +175,11 @@ The manifests directory contains the following files, some of which might requir
175175
If you mirrored the content to local files, you must modify your `catalogSource.yaml` file to remove any backslash (`/`) characters from the `metadata.name` field. Otherwise, when you attempt to create the object, it fails with an "invalid resource name" error.
176176
====
177177
* The `imageContentSourcePolicy.yaml` file defines an `ImageContentSourcePolicy` object that can configure nodes to translate between the image references stored in Operator manifests and the mirrored registry.
178+
+
179+
[NOTE]
180+
====
181+
If your cluster uses an `ImageContentSourcePolicy` object to configure repository mirroring, you can use only global pull secrets for mirrored registries. You cannot add a pull secret to a project.
182+
====
178183
* The `mapping.txt` file contains all of the source images and where to map them in the target registry. This file is compatible with the `oc image mirror` command and can be used to further customize the mirroring configuration.
179184
+
180185
[IMPORTANT]
@@ -192,6 +197,7 @@ $ oc create -f <path/to/manifests/dir>/imageContentSourcePolicy.yaml
192197
+
193198
where `<path/to/manifests/dir>` is the path to the manifests directory for your mirrored content.
194199

200+
195201
You can now create a `CatalogSource` object to reference your mirrored index image and Operator content.
196202

197203
:!index-image-pullspec:

modules/olm-mirroring-package-manifest-catalog.adoc

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -63,6 +63,11 @@ After running the command, a `manifests-<index_image_name>-<random_number>/` dir
6363
--
6464
* The `catalogSource.yaml` file is a basic definition for a `CatalogSource` object that is pre-populated with your catalog image tag and other relevant metadata. This file can be used as is or modified to add the catalog source to your cluster.
6565
* The `imageContentSourcePolicy.yaml` file defines an `ImageContentSourcePolicy` object that can configure nodes to translate between the image references stored in Operator manifests and the mirrored registry.
66+
+
67+
[NOTE]
68+
====
69+
If your cluster uses an `ImageContentSourcePolicy` object to configure repository mirroring, you can use only global pull secrets for mirrored registries. You cannot add a pull secret to a project.
70+
====
6671
* The `mapping.txt` file contains all of the source images and where to map them in the target registry. This file is compatible with the `oc image mirror` command and can be used to further customize the mirroring configuration.
6772
--
6873

modules/update-mirror-repository.adoc

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -59,6 +59,11 @@ $ LOCAL_SECRET_JSON='<path_to_pull_secret>'
5959
----
6060
+
6161
For `<path_to_pull_secret>`, specify the absolute path to and file name of the pull secret for your mirror registry that you created.
62+
+
63+
[NOTE]
64+
====
65+
If your cluster uses an `ImageContentSourcePolicy` object to configure repository mirroring, you can use only global pull secrets for mirrored registries. You cannot add a pull secret to a project.
66+
====
6267

6368
.. Export the release mirror:
6469
+

modules/update-restricted.adoc

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,3 +25,8 @@ $ oc adm upgrade --allow-explicit-upgrade --to-image ${LOCAL_REGISTRY}/${LOCAL_R
2525
<1> The `<sha256_sum_value>` value is the sha256 sum value for the release from the image signature ConfigMap, for example, `@sha256:81154f5c03294534e1eaf0319bef7a601134f891689ccede5d705ef659aa8c92`
2626
+
2727
If you use an `ImageContentSourcePolicy` for the mirror registry, you can use the canonical registry name instead of `LOCAL_REGISTRY`.
28+
+
29+
[NOTE]
30+
====
31+
You can only configure global pull secrets for clusters that have an `ImageContentSourcePolicy` object. You cannot add a pull secret to a project.
32+
====

openshift_images/image-configuration.adoc

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,3 +22,7 @@ include::modules/images-configuration-shortname.adoc[leveloffset=+2]
2222
include::modules/images-configuration-cas.adoc[leveloffset=+2]
2323

2424
include::modules/images-configuration-registry-mirror.adoc[leveloffset=+2]
25+
26+
.Additional resources
27+
28+
For more information about global pull secrets, see xref:../openshift_images/managing_images/using-image-pull-secrets.html#images-update-global-pull-secret_using-image-pull-secrets[Updating the global cluster pull secret].

0 commit comments

Comments
 (0)