@@ -160,12 +160,9 @@ ExecStart=/usr/local/bin/k3s \
160
160
--tls-san kubeapi.corp.cc \
161
161
--tls-san apiserver.cluster.local \
162
162
--tls-san {{ .KubeAPI }} \
163
- {{- if .PodCIDR }}
164
- --cluster-cidr {{ .PodCIDR }} \
165
- {{- end -}}
166
- {{- if .ServiceCIDR }}
167
- --service-cidr {{ .ServiceCIDR }} \
168
- {{- end -}}
163
+ {{if .PodCIDR }}--cluster-cidr {{ .PodCIDR }} \ {{end}}
164
+ {{if .ServiceCIDR }}--service-cidr {{ .ServiceCIDR }} \ {{end}}
165
+ {{if .CNI }}--flannel-backend {{ .CNI }} \ {{ end }}
169
166
{{- if .DataStore }}
170
167
--datastore-endpoint {{ .DataStore }} \
171
168
{{- else}}
@@ -176,19 +173,12 @@ ExecStart=/usr/local/bin/k3s \
176
173
--etcd-expose-metrics \
177
174
--etcd-snapshot-name auto-snapshot \
178
175
--etcd-snapshot-compress \
179
- {{- end -}}
180
- {{- if .LocalStorage }}
181
- --disable servicelb,traefik \
182
- {{else -}}
183
- --disable servicelb,traefik,local-storage \
184
- {{- end -}}
176
+ {{- end}}
185
177
--disable-cloud-controller \
186
178
--system-default-registry {{ .Registry }} \
187
179
--disable-network-policy \
188
180
--disable-helm-controller \
189
- {{if .CNI }}
190
- --flannel-backend {{ .CNI }} \
191
- {{end -}}
181
+ {{if .LocalStorage }}--disable servicelb,traefik \ {{- else }}--disable servicelb,traefik,local-storage \ {{- end }}
192
182
{{- else}}
193
183
agent \
194
184
--server https://{{ .KubeAPI }}:6443 \
0 commit comments