Skip to content

Commit

Permalink
Container App Environment name var
Browse files Browse the repository at this point in the history
  • Loading branch information
manuraf committed Apr 10, 2024
1 parent 62f2918 commit 4d91c6e
Show file tree
Hide file tree
Showing 5 changed files with 18 additions and 7 deletions.
1 change: 1 addition & 0 deletions infra/container_apps/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,7 @@ Deploy container on a Container App instance.
|------|-------------|------|---------|:--------:|
| <a name="input_api_dns_zone_prefix"></a> [api\_dns\_zone\_prefix](#input\_api\_dns\_zone\_prefix) | The dns subdomain. | `string` | `"api.selfcare"` | no |
| <a name="input_app_settings"></a> [app\_settings](#input\_app\_settings) | n/a | <pre>list(object({<br> name = string<br> value = string<br> }))</pre> | n/a | yes |
| <a name="input_cae_name"></a> [cae\_name](#input\_cae\_name) | Container App Environment name | `string` | `"cae-cp"` | no |
| <a name="input_container_app"></a> [container\_app](#input\_container\_app) | Container App configuration | <pre>object({<br> min_replicas = number<br> max_replicas = number<br><br> scale_rules = list(object({<br> name = string<br> custom = object({<br> metadata = map(string)<br> type = string<br> })<br> }))<br><br> cpu = number<br> memory = string<br> })</pre> | n/a | yes |
| <a name="input_dns_zone_prefix"></a> [dns\_zone\_prefix](#input\_dns\_zone\_prefix) | The dns subdomain. | `string` | `"selfcare"` | no |
| <a name="input_env_short"></a> [env\_short](#input\_env\_short) | Environment short name | `string` | n/a | yes |
Expand Down
6 changes: 4 additions & 2 deletions infra/container_apps/env/uat-pnpg/terraform.tfvars
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
is_pnpg = true
env_short = "u"
is_pnpg = true
env_short = "u"
cae_name = "cae"
workload_profile_name = "Consumption"

tags = {
CreatedBy = "Terraform"
Expand Down
10 changes: 6 additions & 4 deletions infra/container_apps/env/uat/terraform.tfvars
Original file line number Diff line number Diff line change
@@ -1,7 +1,9 @@
env_short = "u"
private_dns_name = "selc-u-party-reg-proxy-ca.agreeablesky-f71e6306.westeurope.azurecontainerapps.io"
dns_zone_prefix = "uat.selfcare"
api_dns_zone_prefix = "api.uat.selfcare"
env_short = "u"
private_dns_name = "selc-u-party-reg-proxy-ca.agreeablesky-f71e6306.westeurope.azurecontainerapps.io"
dns_zone_prefix = "uat.selfcare"
api_dns_zone_prefix = "api.uat.selfcare"
cae_name = "cae"
workload_profile_name = "Consumption"

tags = {
CreatedBy = "Terraform"
Expand Down
2 changes: 1 addition & 1 deletion infra/container_apps/locals.tf
Original file line number Diff line number Diff line change
Expand Up @@ -2,5 +2,5 @@ locals {
pnpg_suffix = var.is_pnpg == true ? "-pnpg" : ""
project = "selc-${var.env_short}"

container_app_environment_name = "${local.project}${local.pnpg_suffix}-cae-cp"
container_app_environment_name = "${local.project}${local.pnpg_suffix}-${var.cae_name}"
}
6 changes: 6 additions & 0 deletions infra/container_apps/variables.tf
Original file line number Diff line number Diff line change
Expand Up @@ -85,3 +85,9 @@ variable "workload_profile_name" {
description = "Workload Profile name to use"
default = null
}

variable "cae_name" {
type = string
description = "Container App Environment name"
default = "cae-cp"
}

0 comments on commit 4d91c6e

Please sign in to comment.