@@ -35,14 +35,26 @@ cxxxxxcfedb-0ddd8-4c0f-932b-6adxxxxxxxxxc3ae
3535# Navigate to packer directory
3636cd iac/packer/talos-packer/
3737
38- # Update vars/local.pkrvars.hcl with your settings
38+ # Update vars/local.pkrvars.hcl with your common settings and Proxmox credentials.
3939
40- # Initialize and validate packer
40+ # Initialize and validate packer.
41+ # Note: We now specify both the common 'local' vars and the build-specific vars.
4142packer init -upgrade .
42- packer validate -var-file=" vars/local.pkrvars.hcl" .
4343
44- # Build the template
45- packer build -var-file=" vars/local.pkrvars.hcl" .
44+ # Validate the non-GPU build
45+ packer validate -var-file=" vars/local.pkrvars.hcl" -var-file=" vars/non-gpu.pkrvars.hcl" .
46+
47+ # Validate the GPU build
48+ packer validate -var-file=" vars/local.pkrvars.hcl" -var-file=" vars/gpu.pkrvars.hcl" .
49+
50+
51+ # Build the desired template by specifying the appropriate var file.
52+
53+ # Build the NON-GPU template
54+ packer build -var-file=" vars/local.pkrvars.hcl" -var-file=" vars/non-gpu.pkrvars.hcl" .
55+
56+ # Build the GPU template
57+ packer build -var-file=" vars/local.pkrvars.hcl" -var-file=" vars/gpu.pkrvars.hcl" .
4658```
4759
4860### 3. Terraform - Provisioning Infrastructure
@@ -65,15 +77,15 @@ terraform plan \
6577 -var ' proxmox_api_url=https://192.168.10.11:8006/api2/json' \
6678 -var ' proxmox_node=proxmox-threadripper' \
6779 -var ' proxmox_api_token_id=root@pam!iac' \
68- -var ' proxmox_api_token_secret=c30xxxxxxxb-6aded8a1c3ae ' \
80+ -var ' proxmox_api_token_secret=c3xxxxx ' \
6981 -out .tfplan
7082
7183# Apply the plan
7284terraform apply \
7385 -var ' proxmox_api_url=https://192.168.10.11:8006/api2/json' \
7486 -var ' proxmox_node=proxmox-threadripper' \
7587 -var ' proxmox_api_token_id=root@pam!iac' \
76- -var ' proxmox_api_token_secret=c30cfxxxxxxxaded8a1c3ae '
88+ -var ' proxmox_api_token_secret=c30xxxxx '
7789```
7890
7991** Important:** Take note of the MAC addresses outputted, copy and update in the following step.
0 commit comments