support data disks

This commit is contained in:
Pim Kunis 2023-04-07 16:05:51 +02:00
parent 09a3a61f5f
commit 1fc775f4ee
2 changed files with 12 additions and 6 deletions

7
debian/main.tf vendored
View file

@ -14,13 +14,14 @@ module "tf_debian_vm" {
source = "git::https://git.pim.kunis.nl/pim/tf-debian-vm.git"
name = var.name
admin_authorized_keys = coalesce(var.admin_authorized_keys, module.invariants.admin_authorized_keys)
insecure_password = coalesce(var.insecure_password, false)
use_host_cert = coalesce(var.use_host_cert, true)
insecure_password = var.insecure_password
use_host_cert = var.use_host_cert
disk_pool = coalesce(var.disk_pool, module.invariants.disk_pool)
disk_base = coalesce(var.disk_base, module.invariants.disk_base)
disk_base_pool = coalesce(var.disk_base_pool, module.invariants.disk_base_pool)
cloudinit_pool = coalesce(var.cloudinit_pool, module.invariants.cloudinit_pool)
bridge_name = coalesce(var.bridge_name, module.invariants.bridge_name)
ca_host = coalesce(var.ca_host, module.invariants.ca_host)
memory = coalesce(var.memory, 1024)
memory = var.memory
data_disks = var.data_disks
}

11
debian/variables.tf vendored
View file

@ -9,12 +9,12 @@ variable "admin_authorized_keys" {
variable "insecure_password" {
type = bool
default = null
default = false
}
variable "use_host_cert" {
type = bool
default = null
default = true
}
variable "disk_pool" {
@ -49,5 +49,10 @@ variable "ca_host" {
variable "memory" {
type = number
default = null
default = 1024
}
variable "data_disks" {
type = list(string)
default = []
}