Skip to content

Commit 6c75325

Browse files
committed
ROX-27623: Document CRD upgrade steps for Helm
This is an important step in the 4.8 upgrade for Helm users. Without it, the upgrade command will fail.
1 parent 413ca01 commit 6c75325

File tree

2 files changed

+31
-0
lines changed

2 files changed

+31
-0
lines changed

modules/upgrade-crd-helm.adoc

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+
// * upgrading/upgrade-helm.adoc
4+
:_mod-docs-content-type: PROCEDURE
5+
[id="upgrade-crd-helm{context}"]
6+
= Preparing the custom resource definition for upgrade
7+
8+
[role="_abstract"]
9+
If upgrading from version 4.6 or 4.7, you must prepare the `SecurityPolicy` custom resource definition (CRD) to avoid upgrade errors.
10+
11+
.Procedure
12+
* Apply Helm-specific labels and annotations to the CRD by running the following commands:
13+
14+
[source,terminal]
15+
----
16+
$ oc annotate crd/securitypolicies.config.stackrox.io meta.helm.sh/release-name=stackrox-central-services <1>
17+
----
18+
<1> If you use Kubernetes, enter `kubectl` instead of `oc`. Adjust the value of the `release-name` from the above default of `stackrox-central-services` as needed.
19+
20+
[source,terminal]
21+
----
22+
$ oc annotate crd/securitypolicies.config.stackrox.io meta.helm.sh/release-namespace=stackrox <1>
23+
----
24+
<1> If you use Kubernetes, enter `kubectl` instead of `oc`. Adjust the value of the `release-namespace` from the above default of `stackrox` as needed.
25+
26+
[source,terminal]
27+
----
28+
$ oc label crd/securitypolicies.config.stackrox.io app.kubernetes.io/managed-by=Helm <1>
29+
----
30+
<1> If you use Kubernetes, enter `kubectl` instead of `oc`.

upgrading/upgrade-helm.adoc

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -40,6 +40,7 @@ include::modules/updating-helm-repository.adoc[leveloffset=+1]
4040
* xref:../installing/installing_ocp/install-central-ocp.adoc#install-using-helm-no-customizations-ocp[Installing Central using Helm charts]
4141
* xref:../installing/installing_ocp/install-secured-cluster-ocp.adoc#installing-sc-helm[Installing {product-title-short} on secured clusters by using Helm charts]
4242

43+
include::modules/upgrade-crd-helm.adoc[leveloffset=+1]
4344
include::modules/upgrade-helm-chart.adoc[leveloffset=+1]
4445

4546
include::modules/rollback-helm-upgrade.adoc[leveloffset=+1]

0 commit comments

Comments
 (0)