Files
NewWatari/lxc/uptimekuma/main.tf
Ryan Toler 1543ed0042 Revert "actually use the var"
This reverts commit 73997d7517.
2026-03-22 04:18:51 +00:00

77 lines
1.6 KiB
HCL
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
terraform {
required_providers {
proxmox = {
source = "bpg/proxmox"
version = "0.97.1"
}
}
}
# ------------------------------------------------------------------
# Optional second disk – create it only when the flag is true.
# ------------------------------------------------------------------
resource "proxmox_virtual_environment_container" "var.hostname" {
description = "Managed by Terraform"
start_on_boot = var.start_on_boot
unprivileged = var.unprivileged
features {
nesting = var.nesting_enabled
}
wait_for_ip {
ipv4 = true
}
# ---- Disk(s) ----------------------------------------------------
disk {
datastore_id = var.datastore_id # <- primary disk
size = var.disk_size_gb # in GB
}
# ---- Initialization -------------------------------------------------
initialization {
dns {
servers = ["1.1.1.1", "8.8.8.8"]
}
hostname = var.hostname
ip_config {
ipv4 {
address = var.ip_address
gateway = var.gateway
}
}
user_account {
password = var.password
# keys = [trimspace(tls_private_key.example.public_key_openssh)]
}
}
# ---- Network ----------------------------------------------------
network_interface {
name = "veth0"
mtu = 1450
}
node_name = var.node_name
operating_system {
template_file_id = var.template_file_id
type = "debian"
}
tags = [
"deb13",
"terraform",
]
startup {
order = "3"
up_delay = "60"
down_delay = "60"
}
}