You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: docs/vendor/helm-v2-migrate.md
+30-46Lines changed: 30 additions & 46 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -8,37 +8,33 @@ For additional support migrating existing installations to HelmChart v2, reach o
8
8
9
9
## Migrate to HelmChart v2
10
10
11
-
### Requirement
11
+
### Requirements
12
12
13
-
The HelmChart v2 custom resource is supported for installations that use KOTS v1.99.0 or later. If any of your customers are running a version of KOTS earlier than v1.99.0, see [Support Customers on KOTS Versions Earlier Than v1.99.0](#support-both-v1-v2) below for more information about how to support both HelmChart v1 and HelmChart v2 installations from the same release.
13
+
* The HelmChart v2 custom resource is supported with KOTS v1.99.0 and later. If any of your customers are running a version of KOTS earlier than v1.99.0, see [Support Customers on KOTS Versions Earlier Than v1.99.0](#support-both-v1-v2) below for more information about how to support both HelmChart v1 and HelmChart v2 installations from the same release.
14
+
15
+
* The Helm `--take-ownership` flag is supported with KOTS v1.124.0 and later.
16
+
17
+
* The `kots.io/keep` annotation is supported with KOTS v1.122.0 and later.
14
18
15
19
### Migrate From HelmChart v1 with `useHelmInstall: true`
16
20
17
21
To migrate existing installations from HelmChart v1 with `useHelmInstall: true` to HelmChart v2:
18
22
19
-
1. In a new release, for each HelmChart custom resource in the release, update the `apiVersion` to `kots.io/v1beta2`:
20
-
21
-
```yaml
22
-
# Set apiVersion to kots.io/v1beta2
23
-
apiVersion: kots.io/v1beta2
24
-
kind: HelmChart
25
-
metadata:
26
-
name: samplechart
27
-
spec:
23
+
1. In a development environment, install an application release using the KOTS HelmChart v1 with `useHelmInstall: true` method. You will use this installation to test the migration to HelmChart v2.
28
24
29
-
```
25
+
1. Create a new release containing your application files.
30
26
31
-
1. Configure the HelmChart custom resource to rewrite images, inject image pull secrets, and add backup labels. See [Configuring the HelmChart Custom Resource v2](helm-native-v2-using).
27
+
1. Configure each HelmChart custom resource in the release to update `apiVersion` to `kots.io/v1beta2`, rewrite images, inject image pull secrets, and add backup labels. See [Configuring the HelmChart Custom Resource v2](helm-native-v2-using).
32
28
33
-
1. Promote the release to channel that your team uses for testing.
29
+
1. Promote the release to an internal-only channel that your team uses for testing.
34
30
35
-
1. Access a development environment where there is an instance of your application that was deployed with KOTS HelmChart v1 with `useHelmInstall: true`. In the development environment, log in to the Admin Console and confirm that you can upgrade to the new HelmChart v2 release.
31
+
1. In your development environment, log in to the Admin Console and confirm that you can upgrade to the new HelmChart v2 release.
36
32
37
-
1. When you are ready, promote the release to one or more of your customer-facing channels.
33
+
1. When you are done testing, promote the release to one or more of your customer-facing channels. Customers can follow the standard upgrade process in the Admin Console to update their instance.
38
34
39
35
### Migrate From HelmChart v1 with `useHelmInstall: false`
40
36
41
-
This section describes how to migrate existing HelmChart v1 installations with `useHelmInstall: false`. These migration steps ensure that KOTS does not uninstall any resources that were previously deployed without Helm and that Helm can take ownership of these resources.
37
+
This section describes how to migrate existing HelmChart v1 installations with `useHelmInstall: false`. These migration steps ensure that KOTS does not uninstall any resources that were previously deployed without Helm and that Helm takes ownership of these existing resources.
42
38
43
39
To migrate existing installations from HelmChart v1 and `useHelmInstall: false` to HelmChart v2:
44
40
@@ -55,27 +51,13 @@ To migrate existing installations from HelmChart v1 and `useHelmInstall: false`
55
51
metadata:
56
52
name: samplechart
57
53
spec:
58
-
helmUpgradeFlags:
59
-
- --take-ownership
54
+
helmUpgradeFlags:
55
+
- --take-ownership
60
56
```
61
57
62
-
When the `--take-ownership` flag is enabled, Helm automatically takes ownership of existing resources in the cluster during upgrade.
58
+
When the `--take-ownership` flag is enabled, Helm automatically takes ownership of resources that were previously deployed without Helm during upgrade. The Helm `--take-ownership` flag requires KOTS 1.122.0 or later.
63
59
64
-
1. (Recommended) In the KOTS Application custom resource, set `minKotsVersion: 1.122.0`. The Helm `--take-ownership` flag is not supported on versions of KOTS earlier than 1.122.0.
65
-
66
-
1. For each HelmChart custom resource in the release, update the `apiVersion` to `kots.io/v1beta2`:
67
-
68
-
```yaml
69
-
# Set apiVersion to kots.io/v1beta2
70
-
apiVersion: kots.io/v1beta2
71
-
kind: HelmChart
72
-
metadata:
73
-
name: samplechart
74
-
spec:
75
-
76
-
```
77
-
78
-
1. Configure the HelmChart custom resource to rewrite images, inject pull secrets, and add backup labels. See [Configuring the HelmChart Custom Resource v2](helm-native-v2-using).
60
+
1. Configure each HelmChart custom resource in the release to update `apiVersion` to `kots.io/v1beta2`, rewrite images, inject image pull secrets, and add backup labels. See [Configuring the HelmChart Custom Resource v2](helm-native-v2-using).
79
61
80
62
1. Promote the release to an internal-only channel that your team uses for testing.
81
63
@@ -87,7 +69,7 @@ To migrate existing installations from HelmChart v1 and `useHelmInstall: false`
87
69
88
70
### Migrate From Standard Kubernetes Manifests
89
71
90
-
This section describes how to migrate existing KOTS installations of applications that were previously packaged as standard Kubernetes manifests and are now packaged as one or more Helm charts. These migration steps ensure that KOTS does not uninstall any resources that were adopted into Helm charts and that Helm can take ownership of resources that were previously deployed without Helm.
72
+
This section describes how to migrate existing KOTS installations of applications that were previously packaged as standard Kubernetes manifests and are now packaged as one or more Helm charts. This migration path involves performing two upgrades to ensure that KOTS does not uninstall any resources that were adopted into Helm charts, and that Helm can take ownership of resources that were previously deployed without Helm.
91
73
92
74
To migrate applications that were previously packaged as standard Kubernetes manifests:
93
75
@@ -114,16 +96,18 @@ To migrate applications that were previously packaged as standard Kubernetes man
114
96
- --take-ownership
115
97
```
116
98
117
-
When the `--take-ownership` flag is enabled, Helm automatically takes ownership of existing resources in the cluster during upgrade.
118
-
119
-
1. (Recommended) In the KOTS Application custom resource, set `minKotsVersion: 1.122.0`. The Helm `--take-ownership` flag is not supported on versions of KOTS earlier than 1.122.0.
99
+
When the `--take-ownership` flag is enabled, Helm automatically takes ownership of resources that were previously deployed without Helm during upgrade.
120
100
121
101
1. Save the release.
122
102
123
103
1. Test the upgrade process:
124
104
125
105
1. Promote the first release to an internal-only channel that your team uses for testing.
126
106
107
+
:::note
108
+
Replicated recommends that you mark the release as required by enabling **Prevent this release from being skipped during upgrades** because customers must upgrade to this release first before they can upgrade to the release that migrates their installation to HelmChart v2.
109
+
:::
110
+
127
111
1. In a development environment, install the release.
128
112
129
113
1. Promote the second release to the same channel.
@@ -133,7 +117,7 @@ To migrate applications that were previously packaged as standard Kubernetes man
133
117
1. After you are done testing the migration process, promote the first release containing your application manifests to one or more customer-facing channels.
134
118
135
119
:::note
136
-
Replicated recommends that you mark the release as required because customers must upgrade to this release first before they can upgrade to the release that migrates their installation to HelmChart v2.
120
+
Replicated recommends that you mark the release as required by enabling **Prevent this release from being skipped during upgrades** because customers must upgrade to this release first before they can upgrade to the release that migrates their installation to HelmChart v2.
137
121
:::
138
122
139
123
1. Promote the second release containing your application Helm chart to the same channels.
@@ -148,31 +132,31 @@ To support both installation methods from the same release, include both version
148
132
149
133
When you include both versions of the HelmChart custom resource for a Helm chart, installations with KOTS v1.98.0 or earlier use the v1 method, while installations with KOTS v1.99.0 or later use v2.
150
134
151
-
After all customers are using KOTS v1.99.0 or later, you can remove the HelmChart `kots.io/v1beta1` custom resources so that all customers are using the HelmChart v2 method.
135
+
After all customers are using KOTS v1.99.0 or later, you can remove the HelmChart v1 custom resources so that all customers are using the HelmChart v2 method.
152
136
153
137
## HelmChart v2 Migration FAQs
154
138
155
139
This section includes FAQs related to migrating existing installations to the KOTS HelmChart v2 method.
156
140
157
141
### Which migration scenarios require the `kots.io/keep` annotation?
158
142
159
-
When applied to a resource in a release, the `kots.io/keep` annotation prevents the given resource from being uninstalled. The `kots.io/keep` annotation can be used to prevent KOTS from deleting resources that you intend to adopt into Helm charts, or that were previously deployed with `kubectl apply` and will be deployed with Helm using KOTS HelmChart v2.
143
+
When applied to a resource in a release, the `kots.io/keep` annotation prevents the given resource from being uninstalled. The `kots.io/keep` annotation can be used to prevent KOTS from deleting resources that were either adopted into Helm charts, or that were previously deployed without Helm.
160
144
161
-
To prevent existing resources from being uninstalled, the `kots.io/keep` annotation is required for the following types of migrations:
145
+
To prevent existing resources from being uninstalled during upgrade, the `kots.io/keep` annotation is required for the following types of migrations:
162
146
* Applications previously packaged as Kubernetes manifests migrating to HelmChart v2
163
147
* HelmChart v1 with `useHelmInstall: false` migrating to HelmChart v2
164
148
165
-
`kots.io/keep` is _not_ needed when migrating from HelmChart v1 with `useHelmInstall: true` to HelmChart v1beta2. This is because the HelmChart v1 with `useHelmInstall: true` method deploys the given application with Helm, rather than using `kubectl apply`.
149
+
`kots.io/keep` is _not_ needed when migrating from HelmChart v1 with `useHelmInstall: true` to HelmChart v2.
166
150
167
151
### Which migration scenarios require the `--take-ownership` flag?
168
152
169
-
When the `--take-ownership` flag is enabled, Helm automatically takes ownership of existing resources by automatically adding the required annotations.
153
+
When the `--take-ownership` flag is enabled, Helm automatically takes ownership of resources that were previously deployed to the cluster without Helm.
170
154
171
155
The `--take-ownership` flag is required for the following types of migrations:
172
156
* Applications previously packaged as Kubernetes manifests migrating to HelmChart v2
173
157
* HelmChart v1 with `useHelmInstall: false` migrating to HelmChart v2
174
158
175
-
`--take-ownership` is _not_ needed when migrating from HelmChart v1 with `useHelmInstall: true` to HelmChart v1beta2. This is because the HelmChart v1 with `useHelmInstall: true` method deploys the given application with Helm, rather than using `kubectl apply`.
159
+
`--take-ownership` is _not_ needed when migrating from HelmChart v1 with `useHelmInstall: true` to HelmChart v2.
176
160
177
161
### What is the difference between HelmChart v1 with `useHelmInstall: false` and `useHelmInstall: true`?
0 commit comments