Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix wrong input in tests and examples - production_type for operational_mode #251

Merged
merged 1 commit into from
Jun 7, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions examples/active-active-proxy/main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,7 @@ module "active_active" {
# Private Active / Active Scenario
create_bastion = false
distribution = "rhel"
production_type = "external"
operational_mode = "external"
load_balancer_public = false
load_balancer_type = "load_balancer"
redis_rdb_backup_enabled = true
Expand All @@ -91,4 +91,4 @@ module "active_active" {
vm_node_count = 2
vm_sku = "Standard_D32a_v4"
tags = var.tags
}
}
2 changes: 1 addition & 1 deletion examples/existing-network/main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ module "existing_network" {

# Public Active / Active Scenario
distribution = "ubuntu"
production_type = "external"
operational_mode = "external"
iact_subnet_list = var.iact_subnet_list
vm_node_count = 2
vm_sku = "Standard_D4_v3"
Expand Down
2 changes: 1 addition & 1 deletion examples/standalone_airgap/main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ module "standalone_airgap" {
# Standalone, External Mode, Airgapped Installation Example
distribution = "ubuntu"
iact_subnet_list = var.iact_subnet_list
production_type = "external"
operational_mode = "external"
load_balancer_public = true
load_balancer_type = "load_balancer"
vm_node_count = 1
Expand Down
2 changes: 1 addition & 1 deletion examples/standalone_airgap_dev/main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ module "standalone_airgap_dev" {

# Standalone External Scenario
distribution = "ubuntu"
production_type = "external"
operational_mode = "external"
iact_subnet_list = var.iact_subnet_list
vm_node_count = 1
vm_sku = "Standard_D4_v3"
Expand Down
2 changes: 1 addition & 1 deletion examples/standalone_mounted_disk/main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ module "standalone_mounted_disk" {
iact_subnet_list = var.iact_subnet_list
load_balancer_public = true
load_balancer_type = "application_gateway"
production_type = "disk"
operational_mode = "disk"
vm_node_count = 1
vm_sku = "Standard_D4_v3"
vm_image_id = "ubuntu"
Expand Down
2 changes: 1 addition & 1 deletion tests/private-active-active/main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ module "private_active_active" {
load_balancer_waf_rule_set_version = var.is_replicated_deployment ? "3.1" : "3.2"
redis_use_password_auth = true
redis_use_tls = false
production_type = "external"
operational_mode = "external"
vm_image_id = "rhel"
vm_node_count = 2
vm_sku = "Standard_D16as_v4"
Expand Down
2 changes: 1 addition & 1 deletion tests/private-tcp-active-active/main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@ module "private_tcp_active_active" {
redis_use_tls = true
redis_rdb_backup_enabled = true
redis_rdb_backup_frequency = 60
production_type = "external"
operational_mode = "external"
vm_node_count = 2
vm_sku = "Standard_D32a_v4"
vm_image_id = "rhel"
Expand Down
2 changes: 1 addition & 1 deletion tests/public-active-active/main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ module "public_active_active" {
iact_subnet_list = var.iact_subnet_list
load_balancer_public = true
load_balancer_type = "application_gateway"
production_type = "external"
operational_mode = "external"
redis_use_password_auth = false
redis_use_tls = false
vm_node_count = 2
Expand Down
2 changes: 1 addition & 1 deletion tests/standalone-external/main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ module "standalone_external" {
iact_subnet_list = ["0.0.0.0/0"]
load_balancer_public = true
load_balancer_type = "load_balancer"
production_type = "external"
operational_mode = "external"
vm_node_count = 1
vm_sku = "Standard_D4_v3"
vm_image_id = "ubuntu"
Expand Down
2 changes: 1 addition & 1 deletion tests/standalone-mounted-disk/main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ module "standalone_mounted_disk" {

# Standalone Mounted Disk Mode Scenario
distribution = var.distribution
production_type = "disk"
operational_mode = "disk"
disk_path = "/opt/hashicorp/data"
load_balancer_public = true
load_balancer_type = "load_balancer"
Expand Down
4 changes: 2 additions & 2 deletions variables.tf
Original file line number Diff line number Diff line change
Expand Up @@ -914,12 +914,12 @@ variable "tls_version" {
}

variable "operational_mode" {
default = null
default = "disk"
type = string
description = "Where Terraform Enterprise application data will be stored. Valid values are `external`, `disk`, `active-active` or `null`. Choose `external` when storing application data in an external object storage service and database. Choose `disk` when storing application data in a directory on the Terraform Enterprise instance itself. Chose `active-active` when deploying more than 1 node. Leave it `null` when you want Terraform Enterprise to use its own default."

validation {
condition = contains(["external", "disk", "active-active", null], var.operational_mode)
condition = contains(["external", "disk", "active-active"], var.operational_mode)

error_message = "The operational_mode must be 'external', 'disk', `active-active` or omitted."
}
Expand Down
Loading