fix: talosctl apply-config mode is staged

This commit is contained in:
Devin Buhl authored and GitHub committed 2024-10-30 12:53:31 -04:00
1 parent e895ba359f
commit f7274e4ccc
1 file changed
+2 -4
+2 -4
View File
@@ -27,12 +27,10 @@ tasks:
apply-config:
desc: Apply Talos configuration to a node
cmds:
- '{{if eq .MODE "reboot"}}kubectl drain {{.HOSTNAME}} --ignore-daemonsets --delete-emptydir-data --force{{end}}'
- talosctl apply-config --mode={{.MODE}} --nodes {{.HOSTNAME}} --file {{.TALHELPER_CLUSTER_DIR}}/{{.CLUSTER_NAME}}-{{.HOSTNAME}}.yaml
- talosctl apply-config --mode=staged --nodes {{.HOSTNAME}} --file {{.TALHELPER_CLUSTER_DIR}}/{{.CLUSTER_NAME}}-{{.HOSTNAME}}.yaml
- talosctl --nodes {{.HOSTNAME}} reboot
- talosctl --nodes {{.HOSTNAME}} health --wait-timeout=10m --server=false
- '{{if eq .MODE "reboot"}}kubectl uncordon {{.HOSTNAME}}{{end}}'
vars:
MODE: '{{.MODE | default "no-reboot"}}'
CLUSTER_NAME:
sh: yq '.clusterName' {{.TALHELPER_CONFIG_FILE}}
requires: