create terraform project to setup libvirt on hosts
use SATA drive for atlas OS remove thecloud legacy project
This commit is contained in:
parent
7c7b3e667b
commit
997d9bb0cb
14 changed files with 44 additions and 280 deletions
38
legacy/projects/libvirt_setup/main.tf
Normal file
38
legacy/projects/libvirt_setup/main.tf
Normal file
|
@ -0,0 +1,38 @@
|
|||
terraform {
|
||||
backend "pg" {
|
||||
schema_name = "libvirtsetup"
|
||||
conn_str = "postgresql://terraform@jefke.hyp/terraformstates"
|
||||
}
|
||||
|
||||
required_providers {
|
||||
libvirt = {
|
||||
source = "dmacvicar/libvirt"
|
||||
version = "0.7.1" # https://github.com/dmacvicar/terraform-provider-libvirt/issues/1040
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
# https://libvirt.org/uri.html#libssh-and-libssh2-transport
|
||||
provider "libvirt" {
|
||||
alias = "jefke"
|
||||
uri = "qemu+ssh://root@jefke.hyp/system?known_hosts=/etc/ssh/ssh_known_hosts"
|
||||
}
|
||||
|
||||
provider "libvirt" {
|
||||
alias = "atlas"
|
||||
uri = "qemu+ssh://root@atlas.hyp/system?known_hosts=/etc/ssh/ssh_known_hosts"
|
||||
}
|
||||
|
||||
module "setup_jefke" {
|
||||
source = "../../terraform_modules/setup"
|
||||
providers = {
|
||||
libvirt = libvirt.jefke
|
||||
}
|
||||
}
|
||||
|
||||
module "setup_atlas" {
|
||||
source = "../../terraform_modules/setup"
|
||||
providers = {
|
||||
libvirt = libvirt.atlas
|
||||
}
|
||||
}
|
Reference in a new issue