154 lines
3.4 KiB
HCL
154 lines
3.4 KiB
HCL
# Vultr Variables
|
|
variable "vultr_api_key" {
|
|
description = "Vultr API key"
|
|
type = string
|
|
sensitive = true
|
|
default = ""
|
|
}
|
|
|
|
|
|
|
|
# Proxmox Variables
|
|
variable "proxmox_api_url" {
|
|
description = "Proxmox API URL"
|
|
type = string
|
|
default = "https://10.0.16.231:8006"
|
|
}
|
|
|
|
variable "proxmox_user" {
|
|
description = "Proxmox user for authentication"
|
|
type = string
|
|
default = "root@pam"
|
|
}
|
|
|
|
variable "proxmox_password" {
|
|
description = "Proxmox password"
|
|
type = string
|
|
sensitive = true
|
|
}
|
|
|
|
variable "proxmox_tls_insecure" {
|
|
description = "Allow insecure TLS connections to Proxmox"
|
|
type = bool
|
|
default = true
|
|
}
|
|
|
|
variable "proxmox_nodes" {
|
|
description = "List of Proxmox nodes to distribute VMs across"
|
|
type = list(string)
|
|
default = ["lab02", "lab03", "lab04"]
|
|
}
|
|
|
|
variable "cluster_name" {
|
|
description = "Name prefix for the K3s cluster nodes"
|
|
type = string
|
|
default = "home-k3s"
|
|
}
|
|
|
|
variable "vm_template" {
|
|
description = "Name of the VM template to clone"
|
|
type = string
|
|
default = "debian-13-cloudinit"
|
|
}
|
|
|
|
variable "storage_pool" {
|
|
description = "Storage pool for VM disks"
|
|
type = string
|
|
default = "ceph"
|
|
}
|
|
|
|
variable "network_bridge" {
|
|
description = "Network bridge to use for VMs"
|
|
type = string
|
|
default = "vmbr0"
|
|
}
|
|
|
|
variable "network_cidr" {
|
|
description = "Network CIDR for the cluster"
|
|
type = string
|
|
default = "10.0.16.0/22"
|
|
}
|
|
|
|
variable "network_gateway" {
|
|
description = "Network gateway"
|
|
type = string
|
|
default = "10.0.19.254"
|
|
}
|
|
|
|
variable "control_plane_count" {
|
|
description = "Number of control plane nodes"
|
|
type = number
|
|
default = 3
|
|
}
|
|
|
|
variable "control_plane_cores" {
|
|
description = "Number of CPU cores for control plane nodes"
|
|
type = number
|
|
default = 2
|
|
}
|
|
|
|
variable "control_plane_memory" {
|
|
description = "Memory in MB for control plane nodes"
|
|
type = number
|
|
default = 8192
|
|
}
|
|
|
|
variable "control_plane_disk_size" {
|
|
description = "Disk size for control plane nodes (in GB)"
|
|
type = number
|
|
default = 32
|
|
}
|
|
|
|
variable "control_plane_ip_start" {
|
|
description = "Starting IP offset for control plane nodes"
|
|
type = number
|
|
default = 868 # 10.0.19.100 = offset 868 from 10.0.16.0 (3*256 + 100)
|
|
}
|
|
|
|
variable "worker_count" {
|
|
description = "Number of worker nodes"
|
|
type = number
|
|
default = 3
|
|
}
|
|
|
|
variable "worker_cores" {
|
|
description = "Number of CPU cores for worker nodes"
|
|
type = number
|
|
default = 4
|
|
}
|
|
|
|
variable "worker_memory" {
|
|
description = "Memory in MB for worker nodes"
|
|
type = number
|
|
default = 8192
|
|
}
|
|
|
|
variable "worker_disk_size" {
|
|
description = "Disk size for worker nodes (in GB)"
|
|
type = number
|
|
default = 64
|
|
}
|
|
|
|
variable "worker_ip_start" {
|
|
description = "Starting IP offset for worker nodes"
|
|
type = number
|
|
default = 878 # 10.0.19.110 = offset 878 from 10.0.16.0 (3*256 + 110)
|
|
}
|
|
|
|
variable "ssh_user" {
|
|
description = "SSH user for the VMs"
|
|
type = string
|
|
default = "debian"
|
|
}
|
|
|
|
variable "ssh_public_key" {
|
|
description = "SSH public key for access to VMs"
|
|
type = string
|
|
default = "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIHLyVSEEAEbGZZqwPwEup0XrlTpu3x3iF9ExvvQPA4xN graham@mcintire.me"
|
|
}
|
|
|
|
variable "pdns_vultr_api_key" {
|
|
description = "PowerDNS API key"
|
|
type = string
|
|
default = "eyyMkv7dpDE0gQz1N2FeyUWGRa9FBHGcqcdSCMaaoe"
|
|
}
|