infra/terraform/TALOS_DEPLOYMENT.md
2026-01-11 11:27:34 -06:00

2.9 KiB

Talos Cluster Deployment Guide

Prerequisites

  1. Talos template VM created (VMID 9001 on node1)
  2. Proxmox "home" cluster: node1, node2, node3 (10.0.15.101-103)
  3. SSH access as root (passwordless) to all Proxmox nodes
  4. Environment variables loaded: source .envrc

Configuration

The deployment creates:

  • 3 Control Plane nodes: talos-cp1, talos-cp2, talos-cp3 (VMIDs 200-202)
  • 3 Worker nodes: talos-worker1, talos-worker2, talos-worker3 (VMIDs 210-212)

Nodes are distributed across the cluster:

  • node1: talos-cp1, talos-worker1
  • node2: talos-cp2, talos-worker2
  • node3: talos-cp3, talos-worker3

Deployment Process

Since VMs get DHCP IPs initially, deploy one node at a time to configure static DHCP leases:

Initialize Terraform

cd /Users/graham/dev/infra/terraform
source .envrc
tofu init

Deploy Nodes One at a Time

# Deploy first control plane node
./deploy_talos_node.sh talos_cp1
# Note the MAC address, configure DHCP static lease, verify IP

# Deploy remaining control plane nodes
./deploy_talos_node.sh talos_cp2
./deploy_talos_node.sh talos_cp3

# Deploy worker nodes
./deploy_talos_node.sh talos_worker1
./deploy_talos_node.sh talos_worker2
./deploy_talos_node.sh talos_worker3

Manual Deployment (Alternative)

# Deploy specific node
tofu apply -target="proxmox_virtual_environment_vm.talos_cp1"

# Check MAC address
tofu output talos_cp1_mac

# Continue with next node...

View All MAC Addresses

tofu output | grep mac

Node Specifications

Control Plane

  • CPU: 2 cores (from var.control_plane_cores)
  • Memory: 8192 MB (from var.control_plane_memory)
  • Disk: Inherited from template (~32GB)

Workers

  • CPU: 4 cores (from var.worker_cores)
  • Memory: 8192 MB (from var.worker_memory)
  • Disk: Inherited from template (~32GB)

Post-Deployment

After all VMs are created with static IPs:

  1. Generate Talos configuration in /talos/ directory
  2. Apply Talos configuration to nodes
  3. Bootstrap the Kubernetes cluster
  4. Deploy Ceph CSI driver (see CLAUDE.md)

Troubleshooting

Check VM Status

ssh root@10.0.15.101 "qm list"
ssh root@10.0.15.102 "qm list"
ssh root@10.0.15.103 "qm list"

Start VM Manually

ssh root@10.0.15.101 "qm start 200"

Remove and Recreate Node

tofu destroy -target="proxmox_virtual_environment_vm.talos_cp1"
tofu apply -target="proxmox_virtual_environment_vm.talos_cp1"

Variables

Edit variables.tf to customize:

  • proxmox_home_nodes: Node names
  • control_plane_cores/memory: Control plane resources
  • worker_cores/memory: Worker resources
  • talos_template_vmid: Template VMID
  • talos_storage: Ceph pool name

Files

  • talos_vms.tf: VM resource definitions
  • talos_outputs.tf: MAC addresses and VMID outputs
  • deploy_talos_node.sh: Helper script for one-at-a-time deployment
  • TALOS_DEPLOYMENT.md: This file