Skip to content

Commit b7e39d5

Browse files
author
Steven Smith
committed
Adds the procedure to import manifest list
1 parent 97196f3 commit b7e39d5

File tree

3 files changed

+70
-0
lines changed

3 files changed

+70
-0
lines changed
Lines changed: 44 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,44 @@
1+
// Module included in the following assemblies:
2+
// * openshift_images/image-streams-manage.adoc
3+
4+
:_content-type: PROCEDURE
5+
[id="importing-manifest-list-through-imagestreamimport_{context}"]
6+
= Importing a manifest list through ImageStreamImport
7+
8+
9+
You can use the `ImageStreamImport` resource to find and import image manifests from other container image registries into the cluster. Individual images or an entire image repository can be imported.
10+
11+
Use the following procedure to import a manifest list through the `ImageStreamImport` object with the `importMode` value.
12+
13+
.Procedure
14+
15+
. Create an `ImageStreamImport` YAML file and set the `importMode` parameter to `PreserveOriginal` on the tags that you will import as a manifest list:
16+
+
17+
[source,yaml]
18+
----
19+
apiVersion: image.openshift.io/v1
20+
kind: ImageStreamImport
21+
metadata:
22+
name: app
23+
namespace: myapp
24+
spec:
25+
import: true
26+
images:
27+
- from:
28+
kind: DockerImage
29+
name: <registry>/<user_name>/<image_name>
30+
to:
31+
name: latest
32+
referencePolicy:
33+
type: Source
34+
importPolicy:
35+
importMode: "PreserveOriginal"
36+
----
37+
38+
. Create the `ImageStreamImport` by running the following command:
39+
+
40+
[source,terminal]
41+
----
42+
$ oc create -f <your_imagestreamimport.yaml>
43+
----
44+
Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
// Module included in the following assemblies:
2+
// * assembly/openshift_images/managing-image-streams.adoc
3+
4+
:_content-type: CONCEPT
5+
[id="importmode-configuration-fields_{context}"]
6+
= importMode configuration fields
7+
8+
The following table describes the configuration fields available for the `importMode` value:
9+
10+
[cols="3a,8a",options="header"]
11+
|===
12+
|Parameter |Description
13+
14+
| *Legacy* | The default value for `importMode`. When active, the manifest list is discarded, and a single sub-manifest is imported. The platform is chosen in the following order of priority:
15+
16+
. Tag annotations
17+
. Control plane architecture
18+
. Linux/AMD64
19+
. The first manifest in the list
20+
21+
| *PreserveOriginal* | When active, the original manifest is preserved. For manifest lists, the manifest list and all of its sub-manifests are imported.
22+
23+
|===

openshift_images/image-streams-manage.adoc

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -31,3 +31,6 @@ include::modules/images-imagestream-import.adoc[leveloffset=+2]
3131

3232
include::modules/images-imagestream-import-images-private-registry.adoc[leveloffset=+1]
3333
include::modules/images-allow-pods-to-reference-images-from-secure-registries.adoc[leveloffset=+2]
34+
35+
include::modules/importing-manifest-list-through-imagestreamimport.adoc[leveloffset=+1]
36+
include::modules/importmode-configuration-fields.adoc[leveloffset=+2]

0 commit comments

Comments
 (0)