Changed how all docker images have their version set to use the compose repo
This commit is contained in:
1 parent
8020f416dc
commit
0db6fdf16a
15 files changed
+643
-265
No files matched your search
@@ -36,6 +36,20 @@ locals {
|
||||
# provider alias in providers.tf and a module block here. Everything else
|
||||
# (node contents, common config) lives in the parent repo's terraform.tfvars.
|
||||
|
||||
# butane/versions-sync.yaml goes onto every Flatcar VM through its inline
|
||||
# butane field (the module merges it with butane_file). Inline snippets are
|
||||
# not templated, so the file is read as-is. No VM sets butane in tfvars; one
|
||||
# that did would replace this snippet, not add to it, and lose version sync.
|
||||
locals {
|
||||
flatcar_common_butane = file("${path.module}/butane/versions-sync.yaml")
|
||||
flatcar_with_common = {
|
||||
for hv in ["proxmox", "goose"] : hv => {
|
||||
for name, vm in try(var.nodes[hv].flatcar, {}) :
|
||||
name => merge(vm, { butane = coalesce(vm.butane, local.flatcar_common_butane) })
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
module "proxmox" {
|
||||
source = "./opentofu/modules/proxmox_node"
|
||||
|
||||
@@ -43,7 +57,7 @@ module "proxmox" {
|
||||
storage = var.hypervisors["proxmox"].storage
|
||||
lxc = try(var.nodes["proxmox"].lxc, {})
|
||||
machines = try(var.nodes["proxmox"].machines, {})
|
||||
flatcar = try(var.nodes["proxmox"].flatcar, {})
|
||||
flatcar = local.flatcar_with_common["proxmox"]
|
||||
search_domain = local.node_common.search_domain
|
||||
dns_nameservers = local.node_common.dns_nameservers
|
||||
ssh_key = local.node_common.ssh_key
|
||||
@@ -68,7 +82,7 @@ module "goose" {
|
||||
storage = var.hypervisors["goose"].storage
|
||||
lxc = try(var.nodes["goose"].lxc, {})
|
||||
machines = try(var.nodes["goose"].machines, {})
|
||||
flatcar = try(var.nodes["goose"].flatcar, {})
|
||||
flatcar = local.flatcar_with_common["goose"]
|
||||
search_domain = local.node_common.search_domain
|
||||
dns_nameservers = local.node_common.dns_nameservers
|
||||
ssh_key = local.node_common.ssh_key
|
||||
|
||||
Reference in new issue
Block a user