From 4c010762e09cea49861dfe282981fbfced500569 Mon Sep 17 00:00:00 2001 From: Timtor Date: Thu, 7 Nov 2024 15:39:41 +0800 Subject: [PATCH] chore: reduce control plane number (#480) --- README.md | 4 +- talos/.taskfile.yaml | 60 +++++++------------------- talos/pi4b-3.yaml | 8 ---- talos/{pi4b-2.yaml => pi4b-spare.yaml} | 2 +- 4 files changed, 18 insertions(+), 56 deletions(-) delete mode 100644 talos/pi4b-3.yaml rename talos/{pi4b-2.yaml => pi4b-spare.yaml} (80%) diff --git a/README.md b/README.md index f22bcc6e..781f1f03 100644 --- a/README.md +++ b/README.md @@ -74,8 +74,8 @@ This is a mono repository for my home infrastructure and Kubernetes cluster. I u | Askey RTF8207W | Chunghwa Telecom modem | 1 | | | | Mikrotik RB4011iGS+RM | Router | 1 | | | | Mikrotik CRS328-24P-4S+RM | PoE Switch | 1 | | | -| Raspberry Pi 4B with PoE hat | Kubernetes worker nodes | 3 | 8GB | 960GB SSD Micron 5200 | -| Intel NUC11TNHi50L | Kubernetes control planes | 3 | 16\*2 Mircon CT16G4SFRA32A |
• OS: 960GB SSD Mircon 5300
• Data: 960GB NVMe Mircon 7450 | +| Raspberry Pi 4B with PoE hat | Kubernetes control planes | 1 | 8GB | 960GB SSD Micron 5200 | +| Intel NUC11TNHi50L | Kubernetes worker nodes | 3 | 16\*2 Mircon CT16G4SFRA32A |
• OS: 960GB SSD Mircon 5300
• Data: 960GB NVMe Mircon 7450 | | Ubiquiti Power Distribution Pro | 16p Switched and metered PDU | 1 | | | ## 🤝 Acknowledgments diff --git a/talos/.taskfile.yaml b/talos/.taskfile.yaml index f8892f96..bb6c3162 100644 --- a/talos/.taskfile.yaml +++ b/talos/.taskfile.yaml @@ -25,7 +25,7 @@ tasks: # controlplane apply-controlplane: cmds: - - for: &controlplans [pi4b-1, pi4b-2, pi4b-3] + - for: &controlplans [pi4b-1] task: tal:apply vars: NODE: "{{.ITEM}}" @@ -96,65 +96,35 @@ tasks: vars: NODE: pi4b-1 - # pi4b-2 - render-pi4b-2: + # pi4b-spare + render-pi4b-spare: cmds: - task: tal:render - vars: &pi4b-2-vars - NODE: pi4b-2 + vars: &pi4b-spare-vars + NODE: pi4b-spare SECRET_ENV: *talos-secret - plan-pi4b-2: + plan-pi4b-spare: cmds: - task: tal:plan - vars: *pi4b-2-vars - apply-pi4b-2: + vars: *pi4b-spare-vars + apply-pi4b-spare: cmds: - task: tal:apply - vars: *pi4b-2-vars - upgrade-pi4b-2: + vars: *pi4b-spare-vars + upgrade-pi4b-spare: cmds: - task: tal:upgrade - vars: *pi4b-2-vars - shutdown-pi4b-2: + vars: *pi4b-spare-vars + shutdown-pi4b-spare: cmds: - task: tal:shutdown vars: - NODE: pi4b-2 - reset-pi4b-2: + NODE: pi4b-spare + reset-pi4b-spare: cmds: - task: tal:reset vars: - NODE: pi4b-2 - - # pi4b-3 - render-pi4b-3: - cmds: - - task: tal:render - vars: &pi4b-3-vars - NODE: pi4b-3 - SECRET_ENV: *talos-secret - plan-pi4b-3: - cmds: - - task: tal:plan - vars: *pi4b-3-vars - apply-pi4b-3: - cmds: - - task: tal:apply - vars: *pi4b-3-vars - upgrade-pi4b-3: - cmds: - - task: tal:upgrade - vars: *pi4b-3-vars - shutdown-pi4b-3: - cmds: - - task: tal:shutdown - vars: - NODE: pi4b-3 - reset-pi4b-3: - cmds: - - task: tal:reset - vars: - NODE: pi4b-3 + NODE: pi4b-spare # nuc11tnhi50l-1 render-nuc11tnhi50l-1: diff --git a/talos/pi4b-3.yaml b/talos/pi4b-3.yaml deleted file mode 100644 index d4b91779..00000000 --- a/talos/pi4b-3.yaml +++ /dev/null @@ -1,8 +0,0 @@ ---- -## Header for task scripts -# ip: 192.168.253.3 -# includes: [controlplane.yaml] -machine: - type: controlplane - network: - hostname: amethyst-pi4b-3 diff --git a/talos/pi4b-2.yaml b/talos/pi4b-spare.yaml similarity index 80% rename from talos/pi4b-2.yaml rename to talos/pi4b-spare.yaml index 1dbd920a..ba41d32f 100644 --- a/talos/pi4b-2.yaml +++ b/talos/pi4b-spare.yaml @@ -5,4 +5,4 @@ machine: type: controlplane network: - hostname: amethyst-pi4b-2 + hostname: pi4b-spare