1.0
This commit is contained in:
46
terraform/main.tf
Normal file
46
terraform/main.tf
Normal file
@@ -0,0 +1,46 @@
|
||||
terraform {
|
||||
required_version = ">= 1.0"
|
||||
|
||||
required_providers {
|
||||
proxmox = {
|
||||
source = "telmate/proxmox"
|
||||
version = ">= 2.9.14"
|
||||
}
|
||||
}
|
||||
}
|
||||
provider "proxmox" {
|
||||
pm_api_url = var.proxmox_api_url
|
||||
pm_api_token_id = var.proxmox_api_token_id
|
||||
pm_api_token_secret = var.proxmox_api_token_secret
|
||||
|
||||
}
|
||||
resource "proxmox_lxc" "loustique_lxc" {
|
||||
target_node = "derick"
|
||||
hostname = "web-test-terraform"
|
||||
vmid = 301
|
||||
|
||||
|
||||
ostemplate = "local:vztmpl/ubuntu-24.04-standard_24.04-2_amd64.tar.zst"
|
||||
|
||||
password = "wolaouais"
|
||||
unprivileged = true
|
||||
|
||||
|
||||
cores = 1
|
||||
memory = 512
|
||||
|
||||
rootfs {
|
||||
storage = "local-lvm"
|
||||
size = "8G"
|
||||
}
|
||||
|
||||
|
||||
network {
|
||||
name = "eth0"
|
||||
bridge = "vmbr0"
|
||||
#tag = "2"
|
||||
ip = "dhcp"
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
Reference in New Issue
Block a user