Skip to content

Commit

Permalink
migrated all replicas to new format
Browse files Browse the repository at this point in the history
  • Loading branch information
facchettos committed Jan 30, 2024
1 parent abe44e5 commit 0b517e0
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions charts/k3s/templates/syncer.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ spec:
{{- if .Values.affinity }}
affinity:
{{ toYaml .Values.affinity | indent 8 }}
{{- else if (gt (int .Values.replicas) 1) }}
{{- else if (gt (int ( include "vcluster.replicas" . )) 1) }}
affinity:
podAntiAffinity:
preferredDuringSchedulingIgnoredDuringExecution:
Expand Down Expand Up @@ -207,7 +207,7 @@ spec:
{{- if .Values.pro }}
{{- if .Values.embeddedEtcd.enabled }}
- --etcd-embedded
- --etcd-replicas={{ .Values.replicas }}
- --etcd-replicas={{ include "vcluster.replicas" . }}
{{- end }}
{{- end }}
{{- if .Values.sync.nodes.enableScheduler }}
Expand All @@ -219,7 +219,7 @@ spec:
{{- if .Values.syncer.kubeConfigContextName }}
- --kube-config-context-name={{ .Values.syncer.kubeConfigContextName }}
{{- end }}
{{- if (gt (int .Values.replicas) 1) }}
{{- if (gt (int ( include "vcluster.replicas" . )) 1) }}
- --leader-elect=true
{{- else }}
- --leader-elect=false
Expand Down Expand Up @@ -356,7 +356,7 @@ spec:
{{- range $f := .Values.vcluster.extraArgs }}
- {{ $f }}
{{- end }}
{{- if eq (.Values.replicas | toString | atoi) 1 }}
{{- if eq ( ( include "vcluster.replicas" . ) | toString | atoi) 1 }}
- name: VCLUSTER_NODE_NAME
valueFrom:
fieldRef:
Expand Down

0 comments on commit 0b517e0

Please sign in to comment.