Skip to content

Commit d0ded33

Browse files
authored
Merge pull request #65327 from amolnar-rh/TELCODOCS-1315
TELCODOCS-1315: Correct PGT/CGU for platform update
2 parents 5915eb5 + c510742 commit d0ded33

File tree

1 file changed

+4
-48
lines changed

1 file changed

+4
-48
lines changed

modules/cnf-topology-aware-lifecycle-manager-platform-update.adoc

Lines changed: 4 additions & 48 deletions
Original file line numberDiff line numberDiff line change
@@ -54,15 +54,6 @@ spec:
5454
- quay-intern.example.com/ocp4/openshift-release-dev
5555
source: quay.io/openshift-release-dev/ocp-v4.0-art-dev
5656
- fileName: ClusterVersion.yaml <4>
57-
policyName: "platform-upgrade-prep"
58-
metadata:
59-
name: version
60-
annotations:
61-
ran.openshift.io/ztp-deploy-wave: "1"
62-
spec:
63-
channel: "stable-{product-version}"
64-
upstream: http://upgrade.example.com/images/upgrade-graph_stable-{product-version}
65-
- fileName: ClusterVersion.yaml <5>
6657
policyName: "platform-upgrade"
6758
metadata:
6859
name: version
@@ -77,10 +68,9 @@ spec:
7768
state: "Completed"
7869
----
7970
<1> The `ConfigMap` CR contains the signature of the desired release image to update to.
80-
<2> Shows the image signature of the desired {product-title} release. Get the signature from the `checksum-${OCP_RELASE_NUMBER}.yaml` file you saved when following the procedures in the "Setting up the environment" section.
71+
<2> Shows the image signature of the desired {product-title} release. Get the signature from the `checksum-${OCP_RELEASE_NUMBER}.yaml` file you saved when following the procedures in the "Setting up the environment" section.
8172
<3> Shows the mirror repository that contains the desired {product-title} image. Get the mirrors from the `imageContentSources.yaml` file that you saved when following the procedures in the "Setting up the environment" section.
82-
<4> Shows the `ClusterVersion` CR to update upstream.
83-
<5> Shows the `ClusterVersion` CR to trigger the update. The `channel`, `upstream`, and `desiredVersion` fields are all required for image pre-caching.
73+
<4> Shows the `ClusterVersion` CR to trigger the update. The `channel`, `upstream`, and `desiredVersion` fields are all required for image pre-caching.
8474
+
8575
The `PolicyGenTemplate` CR generates two policies:
8676

@@ -99,44 +89,9 @@ ArgoCD pulls the changes from the Git repository and generates the policies on t
9989
$ oc get policies -A | grep platform-upgrade
10090
----
10191

102-
. Apply the required update resources before starting the platform update with the {cgu-operator}.
103-
104-
.. Save the content of the `platform-upgrade-prep` `ClusterUpgradeGroup` CR with the `du-upgrade-platform-upgrade-prep` policy and the target managed clusters to the `cgu-platform-upgrade-prep.yml` file, as shown in the following example:
105-
+
106-
[source,yaml]
107-
----
108-
apiVersion: ran.openshift.io/v1alpha1
109-
kind: ClusterGroupUpgrade
110-
metadata:
111-
name: cgu-platform-upgrade-prep
112-
namespace: default
113-
spec:
114-
managedPolicies:
115-
- du-upgrade-platform-upgrade-prep
116-
clusters:
117-
- spoke1
118-
remediationStrategy:
119-
maxConcurrency: 1
120-
enable: true
121-
----
122-
123-
.. Apply the policy to the hub cluster by running the following command:
124-
+
125-
[source,terminal]
126-
----
127-
$ oc apply -f cgu-platform-upgrade-prep.yml
128-
----
129-
130-
.. Monitor the update process. Upon completion, ensure that the policy is compliant by running the following command:
131-
+
132-
[source,terminal]
133-
----
134-
$ oc get policies --all-namespaces
135-
----
136-
13792
. Create the `ClusterGroupUpdate` CR for the platform update with the `spec.enable` field set to `false`.
13893

139-
.. Save the content of the platform update `ClusterGroupUpdate` CR with the `du-upgrade-platform-upgrade` policy and the target clusters to the `cgu-platform-upgrade.yml` file, as shown in the following example:
94+
.. Save the content of the platform update `ClusterGroupUpdate` CR with the `du-upgrade-platform-upgrade-prep` and the `du-upgrade-platform-upgrade` policies and the target clusters to the `cgu-platform-upgrade.yml` file, as shown in the following example:
14095
+
14196
[source,yaml]
14297
----
@@ -147,6 +102,7 @@ metadata:
147102
namespace: default
148103
spec:
149104
managedPolicies:
105+
- du-upgrade-platform-upgrade-prep
150106
- du-upgrade-platform-upgrade
151107
preCaching: false
152108
clusters:

0 commit comments

Comments
 (0)