mirror of
https://github.com/tolerryan/NewWatari.git
synced 2026-10-12 07:28:12 +00:00
56 lines
1.2 KiB
HCL
56 lines
1.2 KiB
HCL
terraform {
|
|
required_providers {
|
|
proxmox = {
|
|
source = "bpg/proxmox"
|
|
version = "0.97.1"
|
|
}
|
|
}
|
|
}
|
|
|
|
variable "virtual_environment_endpoint" {
|
|
type = string
|
|
description = "The endpoint for the Proxmox Virtual Environment API (example: https://host:port)"
|
|
}
|
|
|
|
variable "virtual_environment_password" {
|
|
type = string
|
|
description = "The password for the Proxmox Virtual Environment API"
|
|
sensitive = true
|
|
}
|
|
|
|
variable "virtual_environment_username" {
|
|
type = string
|
|
description = "The username and realm for the Proxmox Virtual Environment API (example: root@pam)"
|
|
sensitive = true
|
|
}
|
|
|
|
variable "netbird_token" {
|
|
type = string
|
|
description = "Token used to join new VMs to netbird"
|
|
sensitive = true
|
|
}
|
|
|
|
provider "proxmox" {
|
|
endpoint = var.virtual_environment_endpoint
|
|
username = var.virtual_environment_username
|
|
password = var.virtual_environment_password
|
|
insecure = true
|
|
ssh {
|
|
agent = true
|
|
}
|
|
}
|
|
|
|
locals {
|
|
lxc_containers = [
|
|
"./lxc/downloader"
|
|
]
|
|
}
|
|
|
|
module "lxc_containers" {
|
|
for_each = { for path in local.lxc_containers : path => {} }
|
|
|
|
source = "./modules/lxc_container"
|
|
|
|
dir = each.key # or whatever input your module expects
|
|
}
|