mirror of
https://github.com/openshift/openshift-docs.git
synced 2026-02-05 12:46:18 +01:00
532 lines
15 KiB
Plaintext
532 lines
15 KiB
Plaintext
// Module included in the following assemblies:
|
|
//
|
|
// * disconnected/about-installing-oc-mirror-v2.adoc
|
|
// * microshift_running_apps/microshift_operators//microshift-operators-oc-mirror.com
|
|
|
|
:_mod-docs-content-type: REFERENCE
|
|
[id="oc-mirror-imageset-config-parameters-v2_{context}"]
|
|
= ImageSet configuration parameters for oc-mirror plugin v2
|
|
|
|
The oc-mirror plugin v2 requires an image set configuration file that defines what images to mirror. The following table lists the available parameters for the `ImageSetConfiguration` resource.
|
|
|
|
[NOTE]
|
|
====
|
|
* When selecting bundles for mirroring, the oc-mirror plugin v2 does not automatically detect group/version/kind (GVK) and bundle dependencies. You must explicitly specify the required Operators, their channels, and the Operator versions in the `ImageSetConfiguration` file. For more information, see "opm CLI reference".
|
|
|
|
* Using the `minVersion` and `maxVersion` properties to filter for a specific Operator version range can result in a multiple channel heads error. The error message states that there are `multiple channel heads`. This is because when the filter is applied, the update graph of the Operator is truncated.
|
|
|
|
* OLM requires that every Operator channel contains versions that form an update graph with exactly one end point, that is, the latest version of the Operator. When the filter range is applied, that graph can turn into two or more separate graphs or a graph that has more than one end point.
|
|
|
|
* To avoid this error, do not filter out the latest version of an Operator. If you still run into the error, depending on the Operator, either the `maxVersion` property must be increased or the `minVersion` property must be decreased. Because every Operator graph can be different, you might need to adjust these values until the error resolves.
|
|
====
|
|
|
|
.`ImageSetConfiguration` parameters
|
|
[cols="2,2a,1a",options="header"]
|
|
|===
|
|
|Parameter
|
|
|Description
|
|
|Values
|
|
|
|
|`apiVersion`
|
|
|The API version of the `ImageSetConfiguration` content.
|
|
|String
|
|
Example: `mirror.openshift.io/v2alpha1`
|
|
|
|
ifndef::microshift[]
|
|
|`archiveSize`
|
|
|The maximum size, in GiB, of each archive file within the image set.
|
|
|Integer
|
|
Example: `4`
|
|
|
|
|`kubeVirtContainer`
|
|
|When set to `true`, includes images from the HyperShift KubeVirt CoreOS container.
|
|
|Boolean
|
|
Example `ImageSetConfiguration` file:
|
|
[source,yaml,subs=attributes+]
|
|
----
|
|
apiVersion: mirror.openshift.io/v2alpha1
|
|
kind: ImageSetConfiguration
|
|
mirror:
|
|
platform:
|
|
channels:
|
|
- name: stable-4.16
|
|
minVersion: 4.16.0
|
|
maxVersion: 4.16.0
|
|
kubeVirtContainer: true
|
|
----
|
|
endif::microshift[]
|
|
|
|
|`mirror`
|
|
|The configuration of the image set.
|
|
|Object
|
|
|
|
|`mirror.additionalImages`
|
|
|The additional images configuration of the image set.
|
|
|Array of objects
|
|
|
|
Example:
|
|
[source,yaml]
|
|
----
|
|
additionalImages:
|
|
- name: registry.redhat.io/ubi8/ubi:latest
|
|
----
|
|
|
|
|`mirror.additionalImages.name`
|
|
|The tag or digest of the image to mirror.
|
|
|String
|
|
Example: `registry.redhat.io/ubi8/ubi:latest`
|
|
|
|
|`mirror.blockedImages`
|
|
|List of images with a tag or digest (SHA) to block from mirroring.
|
|
|Array of strings
|
|
Example: `docker.io/library/alpine`
|
|
|
|
ifndef::microshift[]
|
|
|`mirror.helm`
|
|
|The helm configuration of the image set. The oc-mirror plugin does not support helm charts with manually modified `values.yaml` files.
|
|
|Object
|
|
|
|
|`mirror.helm.local`
|
|
|The local helm charts to mirror.
|
|
|Array of objects. For example:
|
|
|
|
[source,yaml]
|
|
----
|
|
local:
|
|
- name: podinfo
|
|
path: /test/podinfo-5.0.0.tar.gz
|
|
----
|
|
|
|
|`mirror.helm.local.charts.imagePaths`
|
|
|The custom path of a container image inside of the local helm chart.
|
|
+
|
|
[NOTE]
|
|
====
|
|
`oc-mirror` detects and mirrors container images from the helm chart by searching well-known paths. You can also specify custom paths using this field.
|
|
====
|
|
+
|
|
[NOTE]
|
|
====
|
|
Operand images, dynamically deployed by Operator controllers at runtime, are typically referenced by environment variables within the controller's deployment template. Before {product-title} 4.20, while `oc-mirror` could access these environment variables, it attempted to mirror all values, including non-image references, for example, log levels, leading to failures. With this update, you can mirror only the container images referenced in these environment variables.
|
|
====
|
|
|Array of string. For example: `"- {.spec.template.spec.custom[*].image}"`.
|
|
|
|
|`mirror.helm.local.name`
|
|
|The name of the local helm chart to mirror.
|
|
|String. For example: `podinfo`.
|
|
|
|
|`mirror.helm.local.path`
|
|
|The path of the local helm chart to mirror.
|
|
|String. For example: `/test/podinfo-5.0.0.tar.gz`.
|
|
|
|
|`mirror.helm.repositories`
|
|
|The remote helm repositories to mirror from.
|
|
|Array of objects. For example:
|
|
|
|
[source,yaml]
|
|
----
|
|
repositories:
|
|
- name: podinfo
|
|
url: https://example.github.io/podinfo
|
|
charts:
|
|
- name: podinfo
|
|
version: 5.0.0
|
|
imagePaths:
|
|
- "{.spec.template.spec.custom[*].image}"
|
|
----
|
|
|
|
|`mirror.helm.repositories.name`
|
|
|The name of the helm repository to mirror from.
|
|
|String. For example: `podinfo`.
|
|
|
|
|`mirror.helm.repositories.url`
|
|
|The URL of the helm repository to mirror from.
|
|
|String. For example: [x-]`https://example.github.io/podinfo`.
|
|
|
|
|`mirror.helm.repositories.charts`
|
|
|The remote helm charts to mirror.
|
|
|Array of objects.
|
|
|
|
|`mirror.helm.repositories.charts.name`
|
|
|The name of the helm chart to mirror.
|
|
|String. For example: `podinfo`.
|
|
|
|
|`mirror.helm.repositories.charts.imagePaths`
|
|
|The custom path of a container image inside of the helm chart.
|
|
+
|
|
[NOTE]
|
|
====
|
|
`oc-mirror` detects and mirrors container images from the helm chart by searching well-known paths. You can also specify custom paths using this field.
|
|
====
|
|
+
|
|
[NOTE]
|
|
====
|
|
Operand images, dynamically deployed by Operator controllers at runtime, are typically referenced by environment variables within the controller's deployment template. Before {product-title} 4.20, while `oc-mirror` could access these environment variables, it attempted to mirror all values, including non-image references, for example, log levels, leading to failures. With this update, you can mirror only the container images referenced in these environment variables.
|
|
====
|
|
|Array of string. For example: `"- {.spec.template.spec.custom[*].image}"`.
|
|
endif::microshift[]
|
|
|
|
|`mirror.operators`
|
|
|The Operators configuration of the image set.
|
|
|Array of objects
|
|
|
|
Example:
|
|
[source,yaml,subs="attributes+"]
|
|
----
|
|
operators:
|
|
- catalog: registry.redhat.io/redhat/redhat-operator-index:{product-version}
|
|
packages:
|
|
- name: elasticsearch-operator
|
|
minVersion: '2.4.0'
|
|
----
|
|
|
|
|`mirror.operators.catalog`
|
|
|The Operator catalog to include in the image set.
|
|
|String
|
|
Example: `registry.redhat.io/redhat/redhat-operator-index:v4.15`
|
|
|
|
|`mirror.operators.full`
|
|
|When `true`, downloads the full catalog, Operator package, or Operator channel.
|
|
|Boolean
|
|
The default value is `false`.
|
|
|
|
|`mirror.operators.packages`
|
|
|The Operator packages configuration.
|
|
|Array of objects
|
|
|
|
Example:
|
|
[source,yaml,subs="attributes+"]
|
|
----
|
|
operators:
|
|
- catalog: registry.redhat.io/redhat/redhat-operator-index:{product-version}
|
|
packages:
|
|
- name: elasticsearch-operator
|
|
minVersion: '5.2.3-31'
|
|
----
|
|
|
|
|`mirror.operators.packages.name`
|
|
|The Operator package name to include in the image set.
|
|
|String
|
|
Example: `elasticsearch-operator`
|
|
|
|
|`mirror.operators.packages.channels`
|
|
|Operator package channel configuration
|
|
|Object
|
|
|
|
|`mirror.operators.packages.channels.name`
|
|
|The Operator channel name, unique within a package, to include in the image set.
|
|
|String
|
|
Eample: `fast` or `stable-v4.15`
|
|
|
|
|`mirror.operators.packages.channels.maxVersion`
|
|
|The highest version of the Operator mirror across all channels in which it exists.
|
|
|String
|
|
Example: `5.2.3-31`
|
|
|
|
|`mirror.operators.packages.channels.minVersion`
|
|
|The lowest version of the Operator to mirror across all channels in which it exists
|
|
|String
|
|
Example: `5.2.3-31`
|
|
|
|
|`mirror.operators.packages.maxVersion`
|
|
|The highest version of the Operator to mirror across all channels in which it exists.
|
|
|String
|
|
Example: `5.2.3-31`
|
|
|
|
|`mirror.operators.packages.minVersion`
|
|
|The lowest version of the Operator to mirror across all channels in which it exists.
|
|
|String
|
|
Example: `5.2.3-31`
|
|
|
|
|`mirror.operators.targetCatalog`
|
|
|An alternative name and optional namespace hierarchy to mirror the referenced catalog as
|
|
|String
|
|
Example: `my-namespace/my-operator-catalog`
|
|
|
|
|`mirror.operators.targetCatalogSourceTemplate`
|
|
|Path on disk for a template to use to complete catalogSource custom resource generated by oc-mirror plugin v2.
|
|
|String
|
|
Example: `/tmp/catalog-source_template.yaml`
|
|
Example of a template file:
|
|
[source,yaml]
|
|
----
|
|
apiVersion: operators.coreos.com/v1alpha1
|
|
kind: CatalogSource
|
|
metadata:
|
|
name: discarded
|
|
namespace: openshift-marketplace
|
|
spec:
|
|
image: discarded
|
|
sourceType: grpc
|
|
updateStrategy:
|
|
registryPoll:
|
|
interval: 30m0s
|
|
----
|
|
|
|
|`mirror.operators.targetTag`
|
|
|An alternative tag to append to the `targetName` or `targetCatalog`.
|
|
|String
|
|
Example: `v1`
|
|
|
|
ifndef::microshift[]
|
|
|`mirror.platform`
|
|
|The platform configuration of the image set.
|
|
|Object
|
|
|
|
|`mirror.platform.architectures`
|
|
|The architecture of the platform release payload to mirror.
|
|
|Array of strings
|
|
Example:
|
|
[source,yaml]
|
|
----
|
|
architectures:
|
|
- amd64
|
|
- arm64
|
|
- multi
|
|
- ppc64le
|
|
- s390x
|
|
----
|
|
|
|
The default value is `amd64`. The value `multi` ensures that the mirroring is supported for all available architectures, eliminating the need to specify individual architectures
|
|
|
|
|`mirror.platform.channels`
|
|
|The platform channel configuration of the image set.
|
|
|Array of objects
|
|
Example:
|
|
[source,yaml,subs="attributes+"]
|
|
----
|
|
channels:
|
|
- name: stable-4.12
|
|
- name: stable-{product-version}
|
|
----
|
|
|
|
|`mirror.platform.channels.full`
|
|
|When `true`, sets the `minVersion` to the first release in the channel and the `maxVersion` to the last release in the channel.
|
|
|Boolean
|
|
The default value is `false`
|
|
|
|
|`mirror.platform.channels.name`
|
|
|Name of the release channel
|
|
|String
|
|
Example: `stable-4.15`
|
|
|
|
|`mirror.platform.channels.minVersion`
|
|
|The minimum version of the referenced platform to be mirrored.
|
|
|String
|
|
Example: `4.12.6`
|
|
|
|
|`mirror.platform.channels.maxVersion`
|
|
|The highest version of the referenced platform to be mirrored.
|
|
|String
|
|
Example: `4.15.1`
|
|
|
|
|`mirror.platform.channels.shortestPath`
|
|
|Toggles shortest path mirroring or full range mirroring.
|
|
|Boolean
|
|
The default value is `false`
|
|
|
|
|`mirror.platform.channels.type`
|
|
|Type of the platform to be mirrored
|
|
|String
|
|
Example: `ocp` or `okd`. The default is `ocp`.
|
|
|
|
|`mirror.platform.graph`
|
|
|Indicates whether the OSUS graph is added to the image set and subsequently published to the mirror.
|
|
|Boolean
|
|
The default value is `false`
|
|
|
|
|`mirror.operators.packages.defaultChannel`
|
|
|Must be defined when excluding the default channel from the filtering.
|
|
|Array of objects. For example:
|
|
|
|
[source,yaml]
|
|
----
|
|
mirror:
|
|
operators:
|
|
- catalog: registry.redhat.io/redhat/redhat-operator-index:v4.21
|
|
packages:
|
|
- name: rhods-operator
|
|
defaultChannel: fast
|
|
channels:
|
|
- name: fast
|
|
----
|
|
endif::microshift[]
|
|
|===
|
|
|
|
[id="delete-imagset-config-parameters_{context}"]
|
|
== DeleteImageSetConfiguration parameters
|
|
|
|
To use remove images with the oc-mirror plugin v2, you must use a `DeleteImageSetConfiguration.yaml` configuration file that defines which images to delete from the mirror registry. The following table lists the available parameters for the `DeleteImageSetConfiguration` resource.
|
|
|
|
.`DeleteImageSetConfiguration` parameters
|
|
[cols="2,2a,1a",options="header"]
|
|
|===
|
|
|Parameter
|
|
|Description
|
|
|Values
|
|
|
|
|`apiVersion`
|
|
|The API version for the `DeleteImageSetConfiguration` content.
|
|
|String
|
|
Example: `mirror.openshift.io/v2alpha1`
|
|
|
|
|`delete`
|
|
|The configuration of the image set to delete.
|
|
|Object
|
|
|
|
|`delete.additionalImages`
|
|
|The additional images configuration of the delete image set.
|
|
|Array of objects
|
|
Example:
|
|
[source,yaml]
|
|
----
|
|
additionalImages:
|
|
- name: registry.redhat.io/ubi8/ubi:latest
|
|
----
|
|
|
|
|`delete.additionalImages.name`
|
|
|The tag or digest of the image to delete.
|
|
|String
|
|
Example: `registry.redhat.io/ubi8/ubi:latest`
|
|
|
|
|`delete.operators`
|
|
|The Operators configuration of the delete image set.
|
|
|Array of objects
|
|
Example:
|
|
[source,yaml]
|
|
----
|
|
operators:
|
|
- catalog: registry.redhat.io/redhat/redhat-operator-index:{product-version}
|
|
packages:
|
|
- name: elasticsearch-operator
|
|
minVersion: '2.4.0'
|
|
----
|
|
|
|
|`delete.operators.catalog`
|
|
|The Operator catalog to include in the delete image set.
|
|
|String
|
|
Example: `registry.redhat.io/redhat/redhat-operator-index:v4.15`
|
|
|
|
|`delete.operators.full`
|
|
|When true, deletes the full catalog, Operator package, or Operator channel.
|
|
|Boolean
|
|
The default value is `false`
|
|
|
|
|`delete.operators.packages`
|
|
|Operator packages configuration
|
|
|Array of objects
|
|
Example:
|
|
[source,yaml]
|
|
----
|
|
operators:
|
|
- catalog: registry.redhat.io/redhat/redhat-operator-index:{product-version}
|
|
packages:
|
|
- name: elasticsearch-operator
|
|
minVersion: '5.2.3-31'
|
|
----
|
|
|
|
|`delete.operators.packages.name`
|
|
|The Operator package name to include in the delete image set.
|
|
|String
|
|
Example: `elasticsearch-operator`
|
|
|
|
|`delete.operators.packages.channels`
|
|
|Operator package channel configuration
|
|
|Object
|
|
|
|
|`delete.operators.packages.channels.name`
|
|
|The Operator channel name, unique within a package, to include in the delete image set.
|
|
|String
|
|
Example: `fast` or `stable-v4.15`
|
|
|
|
|`delete.operators.packages.channels.maxVersion`
|
|
|The highest version of the Operator to delete within the selected channel.
|
|
|String
|
|
Example: `5.2.3-31`
|
|
|
|
|`delete.operators.packages.channels.minVersion`
|
|
|The lowest version of the Operator to delete within the selection in which it exists.
|
|
|String
|
|
Example: `5.2.3-31`
|
|
|
|
|`delete.operators.packages.maxVersion`
|
|
|The highest version of the Operator to delete across all channels in which it exists.
|
|
|String
|
|
Example: `5.2.3-31`
|
|
|
|
|`delete.operators.packages.minVersion`
|
|
|The lowest version of the Operator to delete across all channels in which it exists.
|
|
|String
|
|
Example: `5.2.3-31`
|
|
|
|
ifndef::microshift[]
|
|
|`delete.platform`
|
|
|The platform configuration of the image set
|
|
|Object
|
|
|
|
|`delete.platform.architectures`
|
|
|The architecture of the platform release payload to delete.
|
|
|Array of strings
|
|
Example:
|
|
[source,yaml]
|
|
----
|
|
architectures:
|
|
- amd64
|
|
- arm64
|
|
- multi
|
|
- ppc64le
|
|
- s390x
|
|
----
|
|
|
|
The default value is `amd64`
|
|
|
|
|`delete.platform.channels`
|
|
|The platform channel configuration of the image set.
|
|
|Array of objects
|
|
|
|
Example:
|
|
[source,yaml,subs="attributes+"]
|
|
----
|
|
channels:
|
|
- name: stable-4.12
|
|
- name: stable-{product-version}
|
|
----
|
|
|
|
|`delete.platform.channels.full`
|
|
|When `true`, sets the `minVersion` to the first release in the channel and the `maxVersion` to the last release in the channel.
|
|
|Boolean
|
|
The default value is `false`
|
|
|
|
|`delete.platform.channels.name`
|
|
|Name of the release channel
|
|
|String
|
|
Example: `stable-4.15`
|
|
|
|
|`delete.platform.channels.minVersion`
|
|
|The minimum version of the referenced platform to be deleted.
|
|
|String
|
|
Example: `4.12.6`
|
|
|
|
|`delete.platform.channels.maxVersion`
|
|
|The highest version of the referenced platform to be deleted.
|
|
|String
|
|
Example: `4.15.1`
|
|
|
|
|`delete.platform.channels.shortestPath`
|
|
|Toggles between deleting the shortest path and deleting the full range.
|
|
|Boolean
|
|
The default value is `false`
|
|
|
|
|`delete.platform.channels.type`
|
|
|Type of the platform to be deleted
|
|
|String
|
|
Example: `ocp` or `okd`
|
|
The default is `ocp`
|
|
|
|
|`delete.platform.graph`
|
|
|Determines whether the OSUS graph is deleted as well on the mirror registry as well.
|
|
|Boolean
|
|
The default value is `false`
|
|
endif::microshift[]
|
|
|===
|