|
| 1 | +// Module included in the following assemblies: |
| 2 | +// Epic CNF-2600 (CNF-2133) (4.10), Story TELCODOCS-285 |
| 3 | +// * scalability_and_performance/cnf-talm-for-cluster-upgrades.adoc |
| 4 | + |
| 5 | +:_content-type: PROCEDURE |
| 6 | +[id="talo-about-subscription-crs_{context}"] |
| 7 | += Configuring Operator subscriptions for managed clusters that you install with {cgu-operator} |
| 8 | + |
| 9 | +{cgu-operator} can only approve the install plan for an Operator if the `Subscription` CR of the Operator contains a valid `status` field. You can use the following fields: |
| 10 | + |
| 11 | +* `status.state.AtLatestKnown` for the latest Operator version |
| 12 | +* `status.installedCSV` for a specific Operator version |
| 13 | +
|
| 14 | +.Procedure |
| 15 | + |
| 16 | +. Add one of the following status fields to the `Subscription` CR of the Operator: |
| 17 | + |
| 18 | +.. Add the `status.state.AtLatestKnown` field for the latest Operator version: |
| 19 | ++ |
| 20 | +.Example Subscription CR |
| 21 | +[source,yaml] |
| 22 | +---- |
| 23 | +apiVersion: operators.coreos.com/v1alpha1 |
| 24 | +kind: Subscription |
| 25 | +metadata: |
| 26 | + name: cluster-logging |
| 27 | + namespace: openshift-logging |
| 28 | + annotations: |
| 29 | + ran.openshift.io/ztp-deploy-wave: "2" |
| 30 | +spec: |
| 31 | + channel: "stable" |
| 32 | + name: cluster-logging |
| 33 | + source: redhat-operators |
| 34 | + sourceNamespace: openshift-marketplace |
| 35 | + installPlanApproval: Manual |
| 36 | +status: |
| 37 | + state: AtLatestKnown <1> |
| 38 | +---- |
| 39 | +<1> The `status.state: AtLatestKnown` field is used for the latest Operator version available from the Operator catalog. |
| 40 | + |
| 41 | ++ |
| 42 | +[NOTE] |
| 43 | +==== |
| 44 | +When a new version of the Operator is available in the registry, the associated policy becomes non-compliant. |
| 45 | +==== |
| 46 | + |
| 47 | +.. Add the `status.installedCSV` field for a specific Operator version: |
| 48 | ++ |
| 49 | +.Example Subscription CR |
| 50 | +[source,yaml] |
| 51 | +---- |
| 52 | +apiVersion: operators.coreos.com/v1alpha1 |
| 53 | +kind: Subscription |
| 54 | +metadata: |
| 55 | + name: cluster-logging |
| 56 | + namespace: openshift-logging |
| 57 | + annotations: |
| 58 | + ran.openshift.io/ztp-deploy-wave: "2" |
| 59 | +spec: |
| 60 | + channel: "stable" |
| 61 | + name: cluster-logging |
| 62 | + source: redhat-operators |
| 63 | + sourceNamespace: openshift-marketplace |
| 64 | + installPlanApproval: Manual |
| 65 | +status: |
| 66 | + installedCSV: cluster-logging.v5.7.5 <1> |
| 67 | +---- |
| 68 | +<1> The `status.installedCSV` field with the CSV value is used for a specific version of an Operator, for example, `status.installedCSV: cluster-logging.v5.7.5`. |
| 69 | + |
| 70 | ++ |
| 71 | +. Apply the changed `Subscription` policy to your managed clusters with a `ClusterGroupUpgrade` CR. |
0 commit comments