feat: Initial k8s cluster setup

This commit is contained in:
Peter 2025-10-24 23:41:05 +02:00
parent dc71408e1b
commit 5def74736b
Signed by: Peter
SSH key fingerprint: SHA256:B5tYaxBExaDm74r1px9iVeZ6F/ZDiyiy9SbBqfZYrvg
6 changed files with 233 additions and 0 deletions

View file

@ -0,0 +1,68 @@
terraform {
required_providers {
proxmox = {
source = "Telmate/proxmox"
version = "3.0.2-rc05"
}
talos = {
source = "siderolabs/talos"
version = "0.9.0"
}
}
}
provider "proxmox" {
pm_api_url = "https://10.167.84.10:8006/api2/json"
pm_api_token_id = ""
pm_api_token_secret = ""
pm_tls_insecure = true
}
locals {
talos_version = "1.11.3"
}
module "controlplanes" {
source = "./modules/controlplane"
controlplanes = {
cpu = 4
memory = 4
disk = "40G"
storagepool = "nvme-fastpool"
talos_version = local.talos_version
nodes = [
{
name = "cp01"
ip_address = "10.13.38.20"
},
{
name = "cp02"
ip_address = "10.13.38.21"
},
{
name = "cp03"
ip_address = "10.13.38.22"
}]
}
}
module "workers" {
source = "./modules/worker"
workers = {
cpu = 4
memory = 4
disk = "40G"
storagepool = "nvme-fastpool"
talos_version = local.talos_version
nodes = [
{
name = "worker01"
ip_address = "10.13.38.30"
},
{
name = "worker02"
ip_address = "10.13.38.31"
}]
}
}