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
Suppose you want to automatically install the relevant external cloud provider on all workload clusters.
17
+
This can be accomplished by labeling the clusters with the specific cloud (e.g. AWS, GCP or OpenStack) and then creating a `ClusterResourceSet` for each.
18
+
For example, you could have the following for OpenStack:
19
+
20
+
```yaml
21
+
apiVersion: addons.cluster.x-k8s.io/v1beta1
22
+
kind: ClusterResourceSet
23
+
metadata:
24
+
name: cloud-provider-openstack
25
+
namespace: default
26
+
spec:
27
+
strategy: Reconcile
28
+
clusterSelector:
29
+
matchLabels:
30
+
cloud: openstack
31
+
resources:
32
+
- name: cloud-provider-openstack
33
+
kind: ConfigMap
34
+
- name: cloud-config
35
+
kind: Secret
36
+
```
37
+
38
+
This `ClusterResourceSet` would apply the content of the `Secret` `cloud-config` and of the `ConfigMap` `cloud-provider-openstack` in all workload clusters with the label `cloud=openstack`.
39
+
Suppose you have the file `cloud.conf` that should be included in the `Secret` and `cloud-provider-openstack.yaml` that should be in the `ConfigMap`.
40
+
The `Secret` and `ConfigMap` can then be created in the following way:
Note that it is required that the `Secret` has the type `addons.cluster.x-k8s.io/resource-set` for it to be picked up.
48
+
14
49
## Update from `ApplyOnce` to `Reconcile`
15
50
16
51
The `strategy` field is immutable so existing CRS can't be updated directly. However, CAPI won't delete the managed resources in the target cluster when the CRS is deleted.
0 commit comments