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

Feature/ess performance issue fix dev #290

Draft
wants to merge 110 commits into
base: develop
Choose a base branch
from
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
110 commits
Select commit Hold shift + click to select a range
ebb5391
init
mattwin1 Feb 19, 2024
2817727
added suffix variable for new infra
tejasi15072 Feb 21, 2024
e82409e
updated tf files
tejasi15072 Feb 22, 2024
94acdf2
updated tf files
tejasi15072 Feb 22, 2024
0769a4c
updated variable
tejasi15072 Feb 22, 2024
842dfe3
updated variable
tejasi15072 Feb 22, 2024
cf626f8
added v2 changes
tejasi15072 Feb 23, 2024
3603a96
updated tfplan file
tejasi15072 Feb 23, 2024
f397f47
updated variable
tejasi15072 Feb 23, 2024
7272510
updated suffix code for storage
tejasi15072 Feb 23, 2024
2bed8ef
updated tf files
tejasi15072 Feb 23, 2024
2bb5c5b
updated pipeline
tejasi15072 Feb 23, 2024
b981644
updated pipeline
tejasi15072 Feb 23, 2024
1e29efc
updated yml file
tejasi15072 Feb 23, 2024
1a4a764
updated yml files
tejasi15072 Feb 23, 2024
e04a403
updated yml file
tejasi15072 Feb 23, 2024
2f53e43
updated yml file
tejasi15072 Feb 23, 2024
7896552
updated yml file
tejasi15072 Feb 23, 2024
fd3a414
updated yml file
tejasi15072 Feb 24, 2024
f9377b3
revert commit
tejasi15072 Feb 24, 2024
cfe281b
updated pipeline
tejasi15072 Feb 24, 2024
875c5a1
Revert "updated suffix code for storage"
tejasi15072 Feb 24, 2024
64b875f
updated azure.tf
tejasi15072 Feb 24, 2024
118b0bf
Reapply "updated suffix code for storage"
tejasi15072 Feb 24, 2024
b8e5b2a
updated file
tejasi15072 Feb 24, 2024
00efc14
updated v2 changes
tejasi15072 Feb 24, 2024
4250305
updated apim changes
tejasi15072 Feb 24, 2024
0172148
updated yaml pipeline
tejasi15072 Feb 24, 2024
f71391d
updated apim variables
tejasi15072 Feb 24, 2024
e7c9c40
updated v2 apim changes
tejasi15072 Feb 24, 2024
aba2afc
updated tfplan file
tejasi15072 Feb 24, 2024
bc3fd57
added variable group for dev2
tejasi15072 Feb 26, 2024
574f313
Commenting Devdeploy job for original set of ESS resources and allowi…
Feb 26, 2024
31d0283
Commente dependency parameter
Feb 26, 2024
97ca705
Uncommented terraform apply fom V2 resources
Feb 26, 2024
c51eae1
code deployment for v2
tejasi15072 Feb 27, 2024
8cbb5b6
Merge branch 'Feature/ess-performance-issue-fix' of https://github.co…
tejasi15072 Feb 27, 2024
7035463
updated script
tejasi15072 Feb 27, 2024
3bc01ec
updated yml file
tejasi15072 Feb 27, 2024
64d8cf5
updated tf file
tejasi15072 Feb 27, 2024
f34b728
updated tf
tejasi15072 Feb 27, 2024
4d27989
Webjob helth check changes for v2
harshal11869 Feb 29, 2024
396b120
Webjob healthcheck issue fixed for v2
harshal11869 Feb 29, 2024
b762eac
Webjob health check tests added for v2
harshal11869 Feb 29, 2024
f7fd7c2
updated pipelines
tejasi15072 Feb 29, 2024
9550964
Merge branch 'Feature/ess-performance-issue-fix' of https://github.co…
tejasi15072 Feb 29, 2024
b71bcac
updated apim variables
tejasi15072 Feb 29, 2024
462a373
updated azure pipeline
tejasi15072 Mar 1, 2024
355b995
updated tf files
tejasi15072 Mar 1, 2024
674becf
updated api path variable
tejasi15072 Mar 1, 2024
0a49d73
updated variable.tf
tejasi15072 Mar 1, 2024
0df740c
updated pipeline
tejasi15072 Mar 1, 2024
5c98171
updated pipeline
tejasi15072 Mar 1, 2024
8e85b73
updated tf files
tejasi15072 Mar 1, 2024
df7d817
updated variable.tf
tejasi15072 Mar 1, 2024
1ca5eb4
updated pipeline
tejasi15072 Mar 1, 2024
c7a8dbc
updated pipeline
tejasi15072 Mar 1, 2024
9ddd502
updated tf file
tejasi15072 Mar 1, 2024
7e01106
updated pipeline
tejasi15072 Mar 1, 2024
15ea9ce
updated variable
tejasi15072 Mar 1, 2024
919a15e
updated variable
tejasi15072 Mar 1, 2024
fe6c4a3
updated variable
tejasi15072 Mar 1, 2024
6c7ee0f
updated variable
tejasi15072 Mar 1, 2024
0a175cb
updated terraform
tejasi15072 Mar 1, 2024
f9163f3
updated pipeline
tejasi15072 Mar 1, 2024
1f605bc
updated variable.tf
tejasi15072 Mar 1, 2024
58d137b
updated variables
tejasi15072 Mar 1, 2024
130f2c6
updated ps files
tejasi15072 Mar 1, 2024
aff265c
updated pipeline
tejasi15072 Mar 1, 2024
b0a6932
updated pipeline
tejasi15072 Mar 1, 2024
91d96d9
updated pipeline
tejasi15072 Mar 1, 2024
23c6815
updated tf file
tejasi15072 Mar 1, 2024
e195457
updated pipeline
tejasi15072 Mar 1, 2024
1201f13
updated azure pipeline
tejasi15072 Mar 5, 2024
3af023d
updated pipeline for qa deployment
tejasi15072 Mar 6, 2024
e7a2bb3
updated pipeline
tejasi15072 Mar 6, 2024
8e2ea6a
deploy pipeline
tejasi15072 Mar 6, 2024
426f75e
updated pipeline
tejasi15072 Mar 6, 2024
1971533
updated pipeline
tejasi15072 Mar 6, 2024
b50c14a
updated the pipeline
tejasi15072 Mar 7, 2024
3fdeb17
updated pipeline
tejasi15072 Mar 7, 2024
d3f1ee0
apply terraform command
tejasi15072 Mar 7, 2024
9b486b7
updated pipeline
tejasi15072 Mar 7, 2024
e4395e8
updated main.tf
tejasi15072 Mar 8, 2024
888dae1
Revert "updated main.tf"
tejasi15072 Mar 10, 2024
26178bb
updated pipeline for qa deployment
tejasi15072 Mar 12, 2024
9fb2437
updated live deployment pipeline
tejasi15072 Mar 12, 2024
ece536b
added vulnerability suppression code in nvdsuppression.xml
Mar 12, 2024
126a886
updated pipeline
tejasi15072 Mar 12, 2024
2b48d86
Merge branch 'Feature/ess-performance-issue-fix' of https://github.co…
tejasi15072 Mar 12, 2024
9a0c25a
updated pipeline with live stage
tejasi15072 Mar 12, 2024
cbb3b92
updated pipeline for live deployment
tejasi15072 Mar 13, 2024
2069236
updated pipeline
tejasi15072 Mar 13, 2024
39363ac
updated storage deployment variable
tejasi15072 Mar 13, 2024
85e0623
updated pipeline
tejasi15072 Mar 13, 2024
072004b
updated variable name in main.tf
tejasi15072 Mar 13, 2024
ec7e664
updated pipeline
tejasi15072 Mar 13, 2024
127d9e3
updated variable
tejasi15072 Mar 13, 2024
0fc9405
uncommenting changes
mattwin1 Mar 28, 2024
922e8b0
added ess ui api back
mattwin1 Apr 4, 2024
d5b3d5c
Merge branch 'main' into Feature/ess-performance-issue-fix
mattwin1 Apr 4, 2024
07bd617
Merge branch 'Feature/ess-performance-issue-fix' into Feature/ess-per…
mattwin1 Apr 4, 2024
0ccf3f4
fixed apim vars
mattwin1 Apr 4, 2024
0a42e1e
updated apim main.tf
mattwin1 Apr 4, 2024
3aad3d9
added ui api definition
mattwin1 Apr 4, 2024
3026177
added copyfile task
mattwin1 Apr 4, 2024
d9c06c1
fixed casing in filename
mattwin1 Apr 4, 2024
5c666c8
updated ui api name
mattwin1 Apr 4, 2024
d36778b
added QA into pipeline
mattwin1 Apr 5, 2024
ea55e59
made QA deployable without dependson
mattwin1 Apr 8, 2024
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
32 changes: 31 additions & 1 deletion Deployment/src/Modules/APIM/Modules/ExchangeSetService/main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -226,12 +226,42 @@ resource "azurerm_api_management_product_api" "ess_ui_product_api_mapping" {
product_id = azurerm_api_management_product.ess_ui_product.product_id
}

resource "azurerm_api_management_api" "ess_ui_api" {
resource_group_name = data.azurerm_resource_group.rg.name
api_management_name = data.azurerm_api_management.apim_instance.name
name = lower(replace(var.apim_ui_api_name, " ", "-"))
display_name = var.apim_ui_api_name
description = var.apim_ui_api_description
revision = "1"
path = var.apim_ui_api_path
protocols = ["https"]
service_url = var.apim_api_backend_url

subscription_key_parameter_names {
header = "Ocp-Apim-Subscription-Key"
query = "subscription-key"
}

import {
content_format = "openapi"
content_value = var.apim_ui_openapi
}
}

# Add ESS UI API to ESS Product
resource "azurerm_api_management_product_api" "ess_product_ui_api_mapping" {
resource_group_name = data.azurerm_resource_group.rg.name
api_management_name = data.azurerm_api_management.apim_instance.name
api_name = azurerm_api_management_api.ess_ui_api.name
product_id = azurerm_api_management_product.ess_ui_product.product_id
}

# ESS UI Product poliy
resource "azurerm_api_management_product_policy" "ess_ui_product_policy" {
resource_group_name = data.azurerm_resource_group.rg.name
api_management_name = data.azurerm_api_management.apim_instance.name
product_id = azurerm_api_management_product.ess_ui_product.product_id
depends_on = [azurerm_api_management_product.ess_ui_product, azurerm_api_management_product_api.ess_ui_product_api_mapping]
depends_on = [azurerm_api_management_product.ess_ui_product, azurerm_api_management_product_api.ess_ui_product_api_mapping, azurerm_api_management_product_api.ess_product_ui_api_mapping]

xml_content = <<XML
<policies>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,10 @@ variable "apim_api_path" {
type = string
}

variable "apim_ui_api_path" {
type = string
}

variable "apim_api_backend_url" {
type = string
description = "The URL of the backend service serving the API."
Expand Down Expand Up @@ -51,10 +55,22 @@ variable "apim_api_description" {
type = string
}

variable "apim_ui_api_name" {
type = string
}

variable "apim_ui_api_description" {
type = string
}

variable "apim_api_openapi" {
type = string
}

variable "apim_ui_openapi" {
type = string
}

variable "client_credentials_operation_id" {
type = string
}
Expand Down
1 change: 0 additions & 1 deletion Deployment/src/Modules/APIM/azure.tf
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@ terraform {
required_version = "=1.7.2"
backend "azurerm" {
container_name = "tfstate"
key = "terraform.ess.apim.deployment.tfplan"
}
}

Expand Down
6 changes: 5 additions & 1 deletion Deployment/src/Modules/APIM/main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -3,15 +3,19 @@ module "exchange_set_service" {
apim_name = var.apim_name
apim_rg = var.apim_rg
env_name = local.env_name
apim_api_path = local.apim_api_path
apim_api_path = local.apim_api_path
apim_ui_api_path = local.apim_ui_api_path
apim_api_backend_url = var.apim_api_backend_url
apim_group_name = local.group_name
apim_group_description = var.group_description
apim_ess_product_name = local.product_name
apim_ess_product_description = var.product_description
apim_api_name = local.api_name
apim_ui_api_name = local.ui_api_name
apim_api_description = var.api_description
apim_ui_api_description = var.ui_api_description
apim_api_openapi = local.apim_api_openapi
apim_ui_openapi = local.apim_ui_openapi
product_rate_limit = var.product_rate_limit
product_quota = var.product_quota
client_credentials_operation_id = var.client_credentials_operation_id
Expand Down
31 changes: 26 additions & 5 deletions Deployment/src/Modules/APIM/variables.tf
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,16 @@ variable "api_description" {
default = "The Exchange Set Service APIs to request ENC Exchange Sets for loading onto an ECDIS."
}

variable "ui_api_name" {
type = string
default = "Exchange Set Service UI API"
}

variable "ui_api_description" {
type = string
default = "The Exchange Set Service UI api to facilitate ESS UI Application Requests."
}

variable "ui_product_name" {
type = string
default = "Exchange Set Service UI"
Expand Down Expand Up @@ -111,14 +121,25 @@ variable "cors_origin_values" {
type = string
}

variable "suffix" {
default = ""
}

variable "pathsuffix" {
default = ""
}

locals {
env_name = lower(terraform.workspace)
service_name = "ess"
group_name = local.env_name == "prod" ? var.group_name : "${var.group_name} ${var.env_suffix[local.env_name]}"
product_name = local.env_name == "prod" ? var.product_name : "${var.product_name} ${var.env_suffix[local.env_name]}"
ui_product_name = local.env_name == "prod" ? var.ui_product_name : "${var.ui_product_name} ${var.env_suffix[local.env_name]}"
api_name = local.env_name == "prod" ? var.api_name : "${var.api_name} ${var.env_suffix[local.env_name]}"
apim_api_path = local.env_name == "prod" ? local.service_name : "${local.service_name}-${local.env_name}"
group_name = local.env_name == "prod" ? "${var.group_name}${var.suffix}" : "${var.group_name} ${var.env_suffix[local.env_name]}${var.suffix}"
product_name = local.env_name == "prod" ? "${var.product_name}${var.suffix}" : "${var.product_name} ${var.env_suffix[local.env_name]}${var.suffix}"
ui_product_name = local.env_name == "prod" ? "${var.ui_product_name}${var.suffix}" : "${var.ui_product_name} ${var.env_suffix[local.env_name]}${var.suffix}"
api_name = local.env_name == "prod" ? "${var.api_name}${var.suffix}" : "${var.api_name} ${var.env_suffix[local.env_name]}${var.suffix}"
ui_api_name = local.env_name == "prod" ? "${var.ui_api_name}${var.suffix}" : "${var.ui_api_name} ${var.env_suffix[local.env_name]}${var.suffix}"
apim_api_path = local.env_name == "prod" ? "${local.service_name}${var.pathsuffix}" : "${local.service_name}-${local.env_name}${var.pathsuffix}"
apim_ui_api_path = local.env_name == "prod" ? "${local.service_name}-ui-${var.pathsuffix}" : "${local.service_name}-ui-${local.env_name}${var.pathsuffix}"
apim_api_openapi = file("${path.module}/exchangeSetService_OpenApi_definition.yaml")
apim_ui_openapi = file("${path.module}/exchangeSetService_Ui_OpenApi_definition.yaml")
cors_origins = split(";", var.cors_origin_values)
}
2 changes: 1 addition & 1 deletion Deployment/src/Modules/CacheStorage/main.tf
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
resource "azurerm_storage_account" "ess_cache_storage" {
name = lower("${var.service_name}${var.env_name}cachestorageukho")
name = lower("${var.name}")
resource_group_name = var.resource_group_name
location = var.location
account_tier = "Standard"
Expand Down
9 changes: 4 additions & 5 deletions Deployment/src/Modules/CacheStorage/variables.tf
Original file line number Diff line number Diff line change
Expand Up @@ -6,10 +6,6 @@ variable "location" {
type = string
}

variable "env_name" {
type = string
}

variable "tags" {
}

Expand All @@ -36,4 +32,7 @@ variable "medium_exchange_set_subnets" {
}

variable "large_exchange_set_subnets" {
}
}

variable name {
}
8 changes: 4 additions & 4 deletions Deployment/src/Modules/EventHub/main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -16,21 +16,21 @@ resource "azurerm_eventhub" "eventhub" {
}

resource "azurerm_eventhub_consumer_group" "logstash_consumer_group" {
name = "logstash"
name = "logstash${var.suffix}"
namespace_name = azurerm_eventhub_namespace.eventhub_namespace.name
eventhub_name = azurerm_eventhub.eventhub.name
resource_group_name = var.resource_group_name
}

resource "azurerm_eventhub_consumer_group" "logging_application_consumer_group" {
name = "loggingApplication"
name = "loggingApplication${var.suffix}"
namespace_name = azurerm_eventhub_namespace.eventhub_namespace.name
eventhub_name = azurerm_eventhub.eventhub.name
resource_group_name = var.resource_group_name
}

resource "azurerm_eventhub_authorization_rule" "logstash" {
name = "logstashAccessKey"
name = "logstashAccessKey${var.suffix}"
namespace_name = azurerm_eventhub_namespace.eventhub_namespace.name
eventhub_name = azurerm_eventhub.eventhub.name
resource_group_name = var.resource_group_name
Expand All @@ -40,7 +40,7 @@ resource "azurerm_eventhub_authorization_rule" "logstash" {
}

resource "azurerm_eventhub_authorization_rule" "log" {
name = "logAccessKey"
name = "logAccessKey${var.suffix}"
namespace_name = azurerm_eventhub_namespace.eventhub_namespace.name
eventhub_name = azurerm_eventhub.eventhub.name
resource_group_name = var.resource_group_name
Expand Down
4 changes: 4 additions & 0 deletions Deployment/src/Modules/EventHub/variables.tf
Original file line number Diff line number Diff line change
Expand Up @@ -29,3 +29,7 @@ variable "allowed_ips" {
variable "tags" {

}

variable "suffix" {
default = ""
}
6 changes: 3 additions & 3 deletions Deployment/src/Modules/FulfilmentKeyVault/main.tf
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
data "azurerm_client_config" "current" {}

resource "azurerm_key_vault" "small_exchange_set_kv" {
name = lower("${var.service_name}-ukho-${var.env_name}-sxs-kv")
name = lower("${var.service_name}-ukho-${var.env_name}-sxs-kv${var.suffix}")
location = var.location
resource_group_name = var.resource_group_name
enabled_for_disk_encryption = true
Expand Down Expand Up @@ -69,7 +69,7 @@ resource "azurerm_key_vault_secret" "small_exchange_set_passed_in_secrets" {
#Medium exchange set

resource "azurerm_key_vault" "medium_exchange_set_kv" {
name = lower("${var.service_name}-ukho-${var.env_name}-mxs-kv")
name = lower("${var.service_name}-ukho-${var.env_name}-mxs-kv${var.suffix}")
location = var.location
resource_group_name = var.resource_group_name
enabled_for_disk_encryption = true
Expand Down Expand Up @@ -136,7 +136,7 @@ resource "azurerm_key_vault_secret" "medium_exchange_set_passed_in_secrets" {

#Large exchange set
resource "azurerm_key_vault" "large_exchange_set_kv" {
name = lower("${var.service_name}-ukho-${var.env_name}-lxs-kv")
name = lower("${var.service_name}-ukho-${var.env_name}-lxs-kv${var.suffix}")
location = var.location
resource_group_name = var.resource_group_name
enabled_for_disk_encryption = true
Expand Down
4 changes: 4 additions & 0 deletions Deployment/src/Modules/FulfilmentKeyVault/variables.tf
Original file line number Diff line number Diff line change
Expand Up @@ -53,4 +53,8 @@ variable "large_exchange_set_secrets" {

variable "agent_subnet" {
type = string
}

variable "suffix" {
default = ""
}
6 changes: 3 additions & 3 deletions Deployment/src/Modules/FulfilmentStorage/main.tf
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
resource "azurerm_storage_account" "small_exchange_set_storage" {
name = lower("${var.service_name}${var.env_name}sxsstorageukho")
name = lower("${var.service_name}${var.env_name}sxsstorageukho${var.suffix}")
resource_group_name = var.resource_group_name
location = var.location
account_tier = "Standard"
Expand Down Expand Up @@ -30,7 +30,7 @@ resource "azurerm_storage_queue" "small_exchange_set_storage_queue" {
#Medium exchange set storage

resource "azurerm_storage_account" "medium_exchange_set_storage" {
name = lower("${var.service_name}${var.env_name}mxsstorageukho")
name = lower("${var.service_name}${var.env_name}mxsstorageukho${var.suffix}")
resource_group_name = var.resource_group_name
location = var.location
account_tier = "Standard"
Expand Down Expand Up @@ -61,7 +61,7 @@ resource "azurerm_storage_queue" "medium_exchange_set_storage_queue" {
#Large exchange set storage

resource "azurerm_storage_account" "large_exchange_set_storage" {
name = lower("${var.service_name}${var.env_name}lxsstorageukho")
name = lower("${var.service_name}${var.env_name}lxsstorageukho${var.suffix}")
resource_group_name = var.resource_group_name
location = var.location
account_tier = "Standard"
Expand Down
4 changes: 4 additions & 0 deletions Deployment/src/Modules/FulfilmentStorage/variables.tf
Original file line number Diff line number Diff line change
Expand Up @@ -41,4 +41,8 @@ variable "large_exchange_set_subnets" {

variable "agent_subnet" {
type = string
}

variable "suffix" {
default = ""
}
12 changes: 6 additions & 6 deletions Deployment/src/Modules/FulfilmentWebapps/main.tf
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
resource "azurerm_app_service_plan" "small_exchange_set_app_service_plan" {
count = var.exchange_set_config.SmallExchangeSetInstance
name = "${local.small_exchange_set_name}-${sum([1,count.index])}-asp"
name = "${local.small_exchange_set_name}-${sum([1,count.index])}-asp${var.suffix}"
location = var.location
resource_group_name = var.resource_group_name

Expand All @@ -13,7 +13,7 @@ resource "azurerm_app_service_plan" "small_exchange_set_app_service_plan" {

resource "azurerm_app_service" "small_exchange_set_webapp" {
count = var.exchange_set_config.SmallExchangeSetInstance
name = "${local.small_exchange_set_name}-${sum([1,count.index])}-webapp"
name = "${local.small_exchange_set_name}-${sum([1,count.index])}-webapp${var.suffix}"
location = var.location
resource_group_name = var.resource_group_name
app_service_plan_id = azurerm_app_service_plan.small_exchange_set_app_service_plan[count.index].id
Expand Down Expand Up @@ -84,7 +84,7 @@ resource "azurerm_app_service_slot_virtual_network_swift_connection" "small_exch
#Medium exchange set
resource "azurerm_app_service_plan" "medium_exchange_set_app_service_plan" {
count = var.exchange_set_config.MediumExchangeSetInstance
name = "${local.medium_exchange_set_name}-${sum([1,count.index])}-asp"
name = "${local.medium_exchange_set_name}-${sum([1,count.index])}-asp${var.suffix}"
location = var.location
resource_group_name = var.resource_group_name

Expand All @@ -97,7 +97,7 @@ resource "azurerm_app_service_plan" "medium_exchange_set_app_service_plan" {

resource "azurerm_app_service" "medium_exchange_set_webapp" {
count = var.exchange_set_config.MediumExchangeSetInstance
name = "${local.medium_exchange_set_name}-${sum([1,count.index])}-webapp"
name = "${local.medium_exchange_set_name}-${sum([1,count.index])}-webapp${var.suffix}"
location = var.location
resource_group_name = var.resource_group_name
app_service_plan_id = azurerm_app_service_plan.medium_exchange_set_app_service_plan[count.index].id
Expand Down Expand Up @@ -168,7 +168,7 @@ resource "azurerm_app_service_slot_virtual_network_swift_connection" "medium_exc
#Large exchange set
resource "azurerm_app_service_plan" "large_exchange_set_app_service_plan" {
count = var.exchange_set_config.LargeExchangeSetInstance
name = "${local.large_exchange_set_name}-${sum([1,count.index])}-asp"
name = "${local.large_exchange_set_name}-${sum([1,count.index])}-asp${var.suffix}"
location = var.location
resource_group_name = var.resource_group_name

Expand All @@ -181,7 +181,7 @@ resource "azurerm_app_service_plan" "large_exchange_set_app_service_plan" {

resource "azurerm_app_service" "large_exchange_set_webapp" {
count = var.exchange_set_config.LargeExchangeSetInstance
name = "${local.large_exchange_set_name}-${sum([1,count.index])}-webapp"
name = "${local.large_exchange_set_name}-${sum([1,count.index])}-webapp${var.suffix}"
location = var.location
resource_group_name = var.resource_group_name
app_service_plan_id = azurerm_app_service_plan.large_exchange_set_app_service_plan[count.index].id
Expand Down
4 changes: 4 additions & 0 deletions Deployment/src/Modules/FulfilmentWebapps/variables.tf
Original file line number Diff line number Diff line change
Expand Up @@ -48,4 +48,8 @@ locals {
small_exchange_set_name = "${var.service_name}-${var.env_name}-sxs"
medium_exchange_set_name = "${var.service_name}-${var.env_name}-mxs"
large_exchange_set_name = "${var.service_name}-${var.env_name}-lxs"
}

variable "suffix" {
default = ""
}
2 changes: 1 addition & 1 deletion Deployment/src/Modules/UserIdentity/main.tf
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
resource "azurerm_user_assigned_identity" "ess_service_identity" {
resource_group_name = var.resource_group_name
location = var.location
name = "ess-${var.env_name}-service-identity"
name = "ess-${var.env_name}-service-identity${var.suffix}"
tags = var.tags
}
4 changes: 4 additions & 0 deletions Deployment/src/Modules/UserIdentity/variables.tf
Original file line number Diff line number Diff line change
Expand Up @@ -12,4 +12,8 @@ variable "env_name" {

variable "tags" {

}

variable "suffix" {
default = ""
}
1 change: 0 additions & 1 deletion Deployment/src/azure.tf
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@ terraform {
required_version = "=1.7.2"
backend "azurerm" {
container_name = "tfstate"
key = "terraform.deployment.tfplan"
}
}

Expand Down
Loading
Loading