Skip to content

Commit 5e461b3

Browse files
committed
Rename Operator API to ClusterExtension
1 parent e247ce4 commit 5e461b3

11 files changed

+104
-104
lines changed

_attributes/common-attributes.adoc

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -203,9 +203,16 @@ endif::[]
203203
:osdk_ver: 1.31.0
204204
//Operator SDK version that shipped with the previous OCP 4.x release
205205
:osdk_ver_n1: 1.28.0
206+
//Version-agnostic OLM
207+
:olm-first: Operator Lifecycle Manager (OLM)
208+
:olm: OLM
209+
//Initial version of OLM that shipped with OCP 4, aka "v0"
210+
:olmv0: legacy OLM
211+
:olmv0-first: legacy Operator Lifecycle Manager (OLM)
206212
//Next-gen (OCP 4.14+) Operator Lifecycle Manager, aka "v1"
207213
:olmv1: OLM 1.0
208214
:olmv1-first: Operator Lifecycle Manager (OLM) 1.0
215+
//
209216
:ztp-first: GitOps Zero Touch Provisioning (ZTP)
210217
:ztp: GitOps ZTP
211218
:3no: three-node OpenShift

modules/olmv1-about-target-versions.adoc

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -21,8 +21,8 @@ If you specify a channel in the CR, {olmv1} installs the latest version of the O
2121
.Example CR with a specified channel
2222
[source,yaml]
2323
----
24-
apiVersion: operators.operatorframework.io/v1alpha1
25-
kind: Operator
24+
apiVersion: olm.operatorframework.io/v1alpha1
25+
kind: ClusterExtension
2626
metadata:
2727
name: pipelines-operator
2828
spec:
@@ -38,8 +38,8 @@ If you want to update the version of the Operator that is installed on the clust
3838
.Example CR with the target version specified
3939
[source,yaml]
4040
----
41-
apiVersion: operators.operatorframework.io/v1alpha1
42-
kind: Operator
41+
apiVersion: olm.operatorframework.io/v1alpha1
42+
kind: ClusterExtension
4343
metadata:
4444
name: pipelines-operator
4545
spec:
@@ -53,8 +53,8 @@ If you want to define a range of acceptable versions for an Operator or extensio
5353
.Example CR with a version range specified
5454
[source,yaml]
5555
----
56-
apiVersion: operators.operatorframework.io/v1alpha1
57-
kind: Operator
56+
apiVersion: olm.operatorframework.io/v1alpha1
57+
kind: ClusterExtension
5858
metadata:
5959
name: pipelines-operator
6060
spec:
Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,30 @@
1+
// Module included in the following assemblies:
2+
//
3+
// * operators/olm_v1/arch/olmv1-operator-controller.adoc
4+
5+
:_mod-docs-content-type: CONCEPT
6+
7+
[id="olmv1-clusterextension-api"]
8+
= ClusterExtension API
9+
10+
Operator Controller provides a new `ClusterExtension` API object that is a single resource representing an instance of an installed extension, which includes Operators via the `registry+v1` bundle format. This `clusterextension.olm.operatorframework.io` API streamlines management of installed extensions by consolidating user-facing APIs into a single object.
11+
12+
[IMPORTANT]
13+
====
14+
In {olmv1}, `ClusterExtension` objects are cluster-scoped. This differs from {olmv0} where Operators could be either namespace-scoped or cluster-scoped, depending on the configuration of their related `Subscription` and `OperatorGroup` objects.
15+
16+
For more information about the earlier behavior, see _Multitenancy and Operator colocation_.
17+
====
18+
19+
.Example `ClusterExtension` object
20+
[source,yaml]
21+
----
22+
apiVersion: olm.operatorframework.io/v1alpha1
23+
kind: ClusterExtension
24+
metadata:
25+
name: <operator_name>
26+
spec:
27+
packageName: <package_name>
28+
channel: <channel_name>
29+
version: <version_number>
30+
----

modules/olmv1-deleting-an-operator.adoc

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
[id="olmv1-deleting-an-operator_{context}"]
88
= Deleting an Operator
99

10-
You can delete an Operator and its custom resource definitions (CRDs) by deleting the Operator's custom resource (CR).
10+
You can delete an Operator and its custom resource definitions (CRDs) by deleting the `ClusterExtension` custom resource (CR).
1111

1212
.Prerequisites
1313

@@ -20,13 +20,13 @@ You can delete an Operator and its custom resource definitions (CRDs) by deletin
2020
+
2121
[source,terminal]
2222
----
23-
$ oc delete operator.operators.operatorframework.io <operator_name>
23+
$ oc delete clusterextension <operator_name>
2424
----
2525
+
2626
.Example output
2727
[source,text]
2828
----
29-
operator.operators.operatorframework.io "<operator_name>" deleted
29+
clusterextension.olm.operatorframework.io "<operator_name>" deleted
3030
----
3131

3232
.Verification
@@ -37,7 +37,7 @@ operator.operators.operatorframework.io "<operator_name>" deleted
3737
+
3838
[source,terminal]
3939
----
40-
$ oc get operator.operators.operatorframework.io
40+
$ oc get clusterextensions
4141
----
4242
+
4343
.Example output

modules/olmv1-installing-an-operator.adoc

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -101,8 +101,8 @@ select( .schema == "olm.channel" ) | select( .name == "latest" ) | \
101101
.Example `pipelines-operator.yaml` CR
102102
[source,yaml]
103103
----
104-
apiVersion: operators.operatorframework.io/v1alpha1
105-
kind: Operator
104+
apiVersion: olm.operatorframework.io/v1alpha1
105+
kind: ClusterExtension
106106
metadata:
107107
name: pipelines-operator
108108
spec:
@@ -130,7 +130,7 @@ $ oc apply -f pipeline-operator.yaml
130130
.Example output
131131
[source,text]
132132
----
133-
operator.operators.operatorframework.io/pipelines-operator created
133+
clusterextension.olm.operatorframework.io/pipelines-operator created
134134
----
135135

136136
.Verification
@@ -139,7 +139,7 @@ operator.operators.operatorframework.io/pipelines-operator created
139139
+
140140
[source,terminal]
141141
----
142-
$ oc get operator.operators.operatorframework.io pipelines-operator -o yaml
142+
$ oc get clusterextension pipelines-operator -o yaml
143143
----
144144
+
145145
--
@@ -151,12 +151,12 @@ include::snippets/olmv1-version-range-cr-adomn.adoc[]
151151
====
152152
[source,text]
153153
----
154-
apiVersion: operators.operatorframework.io/v1alpha1
155-
kind: Operator
154+
apiVersion: olm.operatorframework.io/v1alpha1
155+
kind: ClusterExtension
156156
metadata:
157157
annotations:
158158
kubectl.kubernetes.io/last-applied-configuration: |
159-
{"apiVersion":"operators.operatorframework.io/v1alpha1","kind":"Operator","metadata":{"annotations":{},"name":"pipelines-operator"},"spec":{"channel":"latest","packageName":"openshift-pipelines-operator-rh","version":"1.11.x"}}
159+
{"apiVersion":"olm.operatorframework.io/v1alpha1","kind":"ClusterExtension","metadata":{"annotations":{},"name":"pipelines-operator"},"spec":{"channel":"latest","packageName":"openshift-pipelines-operator-rh","version":"1.11.x"}}
160160
creationTimestamp: "2024-01-30T20:06:09Z"
161161
generation: 1
162162
name: pipelines-operator
@@ -205,10 +205,10 @@ metadata:
205205
generation: 2
206206
name: pipelines-operator
207207
ownerReferences:
208-
- apiVersion: operators.operatorframework.io/v1alpha1
208+
- apiVersion: olm.operatorframework.io/v1alpha1
209209
blockOwnerDeletion: true
210210
controller: true
211-
kind: Operator
211+
kind: ClusterExtension
212212
name: pipelines-operator
213213
uid: 4272d228-22e1-419e-b9a7-986f982ee588
214214
resourceVersion: "44464"

modules/olmv1-operator-api.adoc

Lines changed: 0 additions & 32 deletions
This file was deleted.

modules/olmv1-updating-an-operator.adoc

Lines changed: 24 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -91,25 +91,25 @@ select( .schema == "olm.channel" ) | select( .name == "latest" ) | \
9191
+
9292
[source,terminal]
9393
----
94-
$ oc get operator.operators.operatorframework.io <operator_name> -o yaml
94+
$ oc get clusterextension <operator_name> -o yaml
9595
----
9696
+
9797
.Example command
9898
[source,terminal]
9999
----
100-
$ oc get operator.operators.operatorframework.io pipelines-operator -o yaml
100+
$ oc get clusterextension pipelines-operator -o yaml
101101
----
102102
+
103103
.Example output
104104
[%collapsible]
105105
====
106106
[source,text]
107107
----
108-
apiVersion: operators.operatorframework.io/v1alpha1
109-
kind: Operator
108+
apiVersion: olm.operatorframework.io/v1alpha1
109+
kind: ClusterExtension
110110
metadata:
111111
annotations:
112-
kubectl.kubernetes.io/last-applied-configuration: | {"apiVersion":"operators.operatorframework.io/v1alpha1","kind":"Operator","metadata":{"annotations":{},"name":"pipelines-operator"},"spec":{"channel":"latest","packageName":"openshift-pipelines-operator-rh","version":"1.11.1"}}
112+
kubectl.kubernetes.io/last-applied-configuration: | {"apiVersion":"olm.operatorframework.io/v1alpha1","kind":"ClusterExtension","metadata":{"annotations":{},"name":"pipelines-operator"},"spec":{"channel":"latest","packageName":"openshift-pipelines-operator-rh","version":"1.11.1"}}
113113
creationTimestamp: "2024-02-06T17:47:15Z"
114114
generation: 2
115115
name: pipelines-operator
@@ -151,8 +151,8 @@ include::snippets/olmv1-version-range-cr-adomn.adoc[]
151151
.Example `pipelines-operator.yaml` CR
152152
[source,yaml]
153153
----
154-
apiVersion: operators.operatorframework.io/v1alpha1
155-
kind: Operator
154+
apiVersion: olm.operatorframework.io/v1alpha1
155+
kind: ClusterExtension
156156
metadata:
157157
name: pipelines-operator
158158
spec:
@@ -166,8 +166,8 @@ spec:
166166
.Example CR with a version range specified
167167
[source,yaml]
168168
----
169-
apiVersion: operators.operatorframework.io/v1alpha1
170-
kind: Operator
169+
apiVersion: olm.operatorframework.io/v1alpha1
170+
kind: ClusterExtension
171171
metadata:
172172
name: pipelines-operator
173173
spec:
@@ -181,8 +181,8 @@ spec:
181181
.Example CR with a specified channel
182182
[source,yaml]
183183
----
184-
apiVersion: operators.operatorframework.io/v1alpha1
185-
kind: Operator
184+
apiVersion: olm.operatorframework.io/v1alpha1
185+
kind: ClusterExtension
186186
metadata:
187187
name: pipelines-operator
188188
spec:
@@ -196,8 +196,8 @@ spec:
196196
.Example CR with a specified channel and version range
197197
[source,yaml]
198198
----
199-
apiVersion: operators.operatorframework.io/v1alpha1
200-
kind: Operator
199+
apiVersion: olm.operatorframework.io/v1alpha1
200+
kind: ClusterExtension
201201
metadata:
202202
name: pipelines-operator
203203
spec:
@@ -218,7 +218,7 @@ $ oc apply -f pipelines-operator.yaml
218218
.Example output
219219
[source,text]
220220
----
221-
operator.operators.operatorframework.io/pipelines-operator configured
221+
clusterextension.olm.operatorframework.io/pipelines-operator configured
222222
----
223223
+
224224
[TIP]
@@ -227,15 +227,15 @@ You can patch and apply the changes to your CR from the CLI by running the follo
227227
228228
[source,terminal]
229229
----
230-
$ oc patch operator.operators.operatorframework.io/pipelines-operator -p \
230+
$ oc patch clusterextension/pipelines-operator -p \
231231
'{"spec":{"version":"1.12.1"}}' \
232232
--type=merge
233233
----
234234
235235
.Example output
236236
[source,text]
237237
----
238-
operator.operators.operatorframework.io/pipelines-operator patched
238+
clusterextension.olm.operatorframework.io/pipelines-operator patched
239239
----
240240
====
241241

@@ -245,20 +245,20 @@ operator.operators.operatorframework.io/pipelines-operator patched
245245
+
246246
[source,terminal]
247247
----
248-
$ oc get operator.operators.operatorframework.io pipelines-operator -o yaml
248+
$ oc get clusterextension pipelines-operator -o yaml
249249
----
250250
+
251251
.Example output
252252
[%collapsible]
253253
====
254254
[source,yaml]
255255
----
256-
apiVersion: operators.operatorframework.io/v1alpha1
256+
apiVersion: olm.operatorframework.io/v1alpha1
257257
kind: Operator
258258
metadata:
259259
annotations:
260260
kubectl.kubernetes.io/last-applied-configuration: |
261-
{"apiVersion":"operators.operatorframework.io/v1alpha1","kind":"Operator","metadata":{"annotations":{},"name":"pipelines-operator"},"spec":{"channel":"latest","packageName":"openshift-pipelines-operator-rh","version":"1.12.1"}}
261+
{"apiVersion":"olm.operatorframework.io/v1alpha1","kind":"ClusterExtension","metadata":{"annotations":{},"name":"pipelines-operator"},"spec":{"channel":"latest","packageName":"openshift-pipelines-operator-rh","version":"1.12.1"}}
262262
creationTimestamp: "2024-02-06T19:16:12Z"
263263
generation: 4
264264
name: pipelines-operator
@@ -295,21 +295,21 @@ status:
295295
+
296296
[source,terminal]
297297
----
298-
$ oc get operator.operators.operatorframework.io <operator_name> -o yaml
298+
$ oc get clusterextension <operator_name> -o yaml
299299
----
300300
+
301301
.Example output
302302
[%collapsible]
303303
====
304304
[source,text]
305305
----
306-
oc get operator.operators.operatorframework.io pipelines-operator -o yaml
307-
apiVersion: operators.operatorframework.io/v1alpha1
308-
kind: Operator
306+
oc get clusterextension pipelines-operator -o yaml
307+
apiVersion: olm.operatorframework.io/v1alpha1
308+
kind: ClusterExtension
309309
metadata:
310310
annotations:
311311
kubectl.kubernetes.io/last-applied-configuration: |
312-
{"apiVersion":"operators.operatorframework.io/v1alpha1","kind":"Operator","metadata":{"annotations":{},"name":"pipelines-operator"},"spec":{"channel":"latest","packageName":"openshift-pipelines-operator-rh","version":"2.0.0"}}
312+
{"apiVersion":"olm.operatorframework.io/v1alpha1","kind":"ClusterExtension","metadata":{"annotations":{},"name":"pipelines-operator"},"spec":{"channel":"latest","packageName":"openshift-pipelines-operator-rh","version":"2.0.0"}}
313313
creationTimestamp: "2024-02-06T17:47:15Z"
314314
generation: 1
315315
name: pipelines-operator

modules/olmv1-version-range-comparisons.adoc

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -40,8 +40,8 @@ You can specify a version range in an Operator or extension's CR by using a rang
4040
.Example version range comparison
4141
[source,yaml]
4242
----
43-
apiVersion: operators.operatorframework.io/v1alpha1
44-
kind: Operator
43+
apiVersion: olm.operatorframework.io/v1alpha1
44+
kind: ClusterExtension
4545
metadata:
4646
name: pipelines-operator
4747
spec:

operators/olm_v1/arch/olmv1-operator-controller.adoc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ Operator Controller is the central component of {olmv1-first} and consumes the o
1111
:FeatureName: {olmv1}
1212
include::snippets/technology-preview.adoc[]
1313

14-
include::modules/olmv1-operator-api.adoc[leveloffset=+1]
14+
include::modules/olmv1-clusterextension-api.adoc[leveloffset=+1]
1515
[role="_additional-resources"]
1616
.Additional resources
1717

0 commit comments

Comments
 (0)