diff --git a/environments/skeleton/{{cookiecutter.environment}}/tofu/inventory.tf b/environments/skeleton/{{cookiecutter.environment}}/tofu/inventory.tf index 0af7eb30b..f86d38205 100644 --- a/environments/skeleton/{{cookiecutter.environment}}/tofu/inventory.tf +++ b/environments/skeleton/{{cookiecutter.environment}}/tofu/inventory.tf @@ -13,6 +13,7 @@ resource "local_file" "hosts" { } resource "local_file" "partitions" { + count = var.autogenerated_partitions_enabled ? 1: 0 content = templatefile("${path.module}/partitions.tpl", { "compute_groups": module.compute, diff --git a/environments/skeleton/{{cookiecutter.environment}}/tofu/variables.tf b/environments/skeleton/{{cookiecutter.environment}}/tofu/variables.tf index 52cc3a605..b26fd506b 100644 --- a/environments/skeleton/{{cookiecutter.environment}}/tofu/variables.tf +++ b/environments/skeleton/{{cookiecutter.environment}}/tofu/variables.tf @@ -24,6 +24,12 @@ variable "key_pair" { description = "Name of an existing keypair in OpenStack" } +variable "autogenerated_partitions_enabled" { + type = bool + description = "Whether or not to template partitions.yml" + default = true +} + variable "control_node_flavor" { type = string description = "Flavor name for control node"