diff --git a/configs/hecate.tethys.yaml b/configs/hecate.tethys.yaml index a24b0a1..03b100b 100644 --- a/configs/hecate.tethys.yaml +++ b/configs/hecate.tethys.yaml @@ -62,7 +62,26 @@ control_planes: - titan-0a - titan-0b - titan-0c -workers: [] +workers: + - titan-04 + - titan-05 + - titan-06 + - titan-07 + - titan-08 + - titan-09 + - titan-10 + - titan-11 + - titan-12 + - titan-13 + - titan-14 + - titan-15 + - titan-17 + - titan-18 + - titan-19 + - titan-20 + - titan-21 + - titan-22 + - titan-24 local_bootstrap_paths: - infrastructure/core - clusters/atlas/flux-system diff --git a/configs/hecate.titan-db.yaml b/configs/hecate.titan-db.yaml index 2e8bd68..82bb826 100644 --- a/configs/hecate.titan-db.yaml +++ b/configs/hecate.titan-db.yaml @@ -62,7 +62,26 @@ control_planes: - titan-0a - titan-0b - titan-0c -workers: [] +workers: + - titan-04 + - titan-05 + - titan-06 + - titan-07 + - titan-08 + - titan-09 + - titan-10 + - titan-11 + - titan-12 + - titan-13 + - titan-14 + - titan-15 + - titan-17 + - titan-18 + - titan-19 + - titan-20 + - titan-21 + - titan-22 + - titan-24 local_bootstrap_paths: - infrastructure/core - clusters/atlas/flux-system diff --git a/scripts/install.sh b/scripts/install.sh index b148d99..bfb30a0 100755 --- a/scripts/install.sh +++ b/scripts/install.sh @@ -208,6 +208,27 @@ migrate_hecate_config() { role="$(read_hecate_role)" local inventory_block local managed_block + local workers_block + workers_block='workers: + - titan-04 + - titan-05 + - titan-06 + - titan-07 + - titan-08 + - titan-09 + - titan-10 + - titan-11 + - titan-12 + - titan-13 + - titan-14 + - titan-15 + - titan-17 + - titan-18 + - titan-19 + - titan-20 + - titan-21 + - titan-22 + - titan-24' if [[ "${role}" == "coordinator" ]]; then inventory_block='ssh_node_hosts: titan-db: 192.168.22.10 @@ -315,6 +336,11 @@ migrate_hecate_config() { changed=1 fi fi + if grep -Eq '^workers:[[:space:]]*\[\][[:space:]]*$' "${CONF_DIR}/hecate.yaml"; then + perl -0pi -e 's#workers:\s*\[\]\n#'"${workers_block}"'\n#s' "${CONF_DIR}/hecate.yaml" + echo "[install] hydrated workers inventory for startup/shutdown orchestration" + changed=1 + fi if [[ -n "${managed_block}" ]]; then if grep -Eq '^ssh_managed_nodes:[[:space:]]*\[\][[:space:]]*$' "${CONF_DIR}/hecate.yaml"; then