Skip to content

Commit dc25c0d

Browse files
add noe and chamge sshcreds name
Signed-off-by: Nikita Korolev <nikita.korolev@flant.com>
1 parent b83d710 commit dc25c0d

3 files changed

Lines changed: 11 additions & 3 deletions

File tree

test/dvp-static-cluster/charts/cluster-config/templates/master-nodes.yaml

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,14 @@
44
{{- $totalNodes = add $totalNodes .count -}}
55
{{- end -}}
66

7+
{{/*
8+
CAPS (Cluster API Static Provider) manages static nodes, but during bootstrap it may fail
9+
to take control of the first master node, which can break the bootstrap process.
10+
11+
To avoid this, the first master (index 0) — the one that was bootstrapped initially —
12+
is intentionally excluded from CAPS management. Only masters with index >= 1 are registered
13+
as StaticInstance resources and counted in the NodeGroup.
14+
*/}}
715
{{- $masterCount := $.Values.instances.masterNodes.count | int -}}
816
{{- if gt $masterCount 1 -}}
917
{{- $staticCount := sub $masterCount 1 -}}
@@ -45,6 +53,6 @@ spec:
4553
address: {{ index $.Values.discovered.vmIPs $vmName }}
4654
credentialsRef:
4755
kind: SSHCredentials
48-
name: mvp-static
56+
name: dvp-stataic
4957
{{- end }}
5058
{{- end }}

test/dvp-static-cluster/charts/cluster-config/templates/nodes.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ spec:
3838
address: {{ index $.Values.discovered.vmIPs $vmName }}
3939
credentialsRef:
4040
kind: SSHCredentials
41-
name: mvp-static
41+
name: dvp-stataic
4242
{{- end }}
4343

4444
{{- end }}

test/dvp-static-cluster/charts/cluster-config/templates/ssh-creds.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
apiVersion: deckhouse.io/v1alpha2
33
kind: SSHCredentials
44
metadata:
5-
name: mvp-static
5+
name: dvp-stataic
66
spec:
77
user: cloud
88
privateSSHKey: {{ .Values.discovered.privateSSHKeyBase64 }}

0 commit comments

Comments
 (0)