support data disks

This commit is contained in:
Pim Kunis 2023-04-07 16:02:02 +02:00
parent 65a218f076
commit c80ec7a6f6
2 changed files with 12 additions and 0 deletions

View file

@ -78,6 +78,13 @@ resource "libvirt_domain" "debian" {
volume_id = libvirt_volume.debian.id
}
dynamic "disk" {
for_each = var.data_disks
content {
volume_id = disk.value
}
}
network_interface {
bridge = var.bridge_name
hostname = var.name

View file

@ -54,3 +54,8 @@ variable "bridge_name" {
variable "ca_host" {
type = string
}
variable "data_disks" {
type = list(string)
default = []
}