It seems like the libvirt provider only takes pre-defined cloud images. I create my own base qcow2 image that is local to the hypervisor and wish to use it as source file with terraform libvirtd.
Is this doable?
Config using cloud image:
resource "libvirt_volume" "terraform-test" {
name = "terraform-test.qcow2"
pool = "default"
source = "https://cloud.debian.org/images/cloud/buster/daily/20200324-210/debian-10-nocloud-amd64-daily-20200324-210.qcow2"
format = "qcow2"
Instead, I'd like to use a local file in the hypervisor like so:
resource "libvirt_volume" "terraform-test" {
name = "terraform-test.qcow2"
pool = "default"
source = "/var/lib/libvirt/images/base-image.qcow2"
format = "qcow2"
Error: Error while determining image type for /var/lib/libvirt/images/base-image.qcow2: Error while opening /var/lib/libvirt/images/base-image.qcow2: open /var/lib/libvirt/images/base-image.qcow2: no such file or directory