Open CieNTi opened 2 years ago
Fedora 34 (running all Terraform commands under Docker)
$ terraform -v Terraform v1.0.4 on linux_amd64 + provider registry.terraform.io/dmacvicar/libvirt v0.6.10 + provider registry.terraform.io/hashicorp/cloudinit v2.2.0 + provider registry.terraform.io/hashicorp/local v2.1.0
$ terraform-provider-libvirt -version /home/user/.terraform.d/plugin-cache/registry.terraform.io/dmacvicar/libvirt/0.6.10/linux_amd64/terraform-provider-libvirt_v0.6.10 0.6.10
There is no official documentation on how to correctly set the known_hosts file, and the information found is confusing or wrong.
known_hosts
According the terraform-provider-libvirt page (or the GitHub source), and with some exceptions, the connection URIs will follow libvirt Connection URIs.
Taking a look into libvirt URIs Extra parameters, it is defined known_hosts as the expected parameter (and at the same time is not supported by ssh transport, which sounds really weird to me. It is maybe an errata, but I didn't checked it).
ssh
Taking a look into terraform-provider-libvirt code:
${HOME}/.ssh/known_hosts
knownhosts
Apart of that, there is no example or documentation I could found about this.
Is this the expected behaviour, as official libvirt does not support known_hosts for ssh transport? Or it is just a terraform-provider-libvirt errata?
terraform-provider-libvirt
Thanks for your provider, time and support.
provider "libvirt" { uri = "qemu+ssh://user@host/system?known_hosts=/path/to/known_hosts" }
provider "libvirt" { uri = "qemu+ssh://user@host/system?knownhosts=/path/to/known_hosts" }
Nothing to add
System Information
Linux distribution
Fedora 34 (running all Terraform commands under Docker)
Terraform version
Provider and libvirt versions
Checklist
Description of Issue/Question
There is no official documentation on how to correctly set the
known_hosts
file, and the information found is confusing or wrong.According the terraform-provider-libvirt page (or the GitHub source), and with some exceptions, the connection URIs will follow libvirt Connection URIs.
Taking a look into libvirt URIs Extra parameters, it is defined
known_hosts
as the expected parameter (and at the same time is not supported byssh
transport, which sounds really weird to me. It is maybe an errata, but I didn't checked it).Taking a look into terraform-provider-libvirt code:
${HOME}/.ssh/known_hosts
, as one may expectknownhosts
URI optionApart of that, there is no example or documentation I could found about this.
Is this the expected behaviour, as official libvirt does not support
known_hosts
forssh
transport? Or it is just aterraform-provider-libvirt
errata?Thanks for your provider, time and support.
Not working setup
Working setup
Additional information:
Nothing to add