Skip to content

Commit

Permalink
update env variables for web
Browse files Browse the repository at this point in the history
  • Loading branch information
kahlstrm committed Jan 20, 2024
1 parent a986a38 commit 2351e55
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion modules/web/app/main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -35,13 +35,17 @@ resource "azurerm_linux_web_app" "frontend" {
WEBSITES_PORT = 3000
PORT = 3000
NEXT_REVALIDATION_KEY = random_password.revalidation_key.result
SERVER_URL = "https://${azurerm_linux_web_app.cms.default_hostname}"
PUBLIC_SERVER_URL = "https://${azurerm_linux_web_app.cms.default_hostname}"
}
}
resource "random_password" "payload_secret" {
length = 32
special = true
}
resource "random_password" "payload_password" {
length = 32
special = true
}
resource "azurerm_linux_web_app" "cms" {
name = "tikweb-cms-${terraform.workspace}"
location = var.resource_group_location
Expand Down Expand Up @@ -79,6 +83,8 @@ resource "azurerm_linux_web_app" "cms" {
PAYLOAD_MONGO_DB_NAME = "cms"
PAYLOAD_SECRET = random_password.payload_secret.result
PAYLOAD_REVALIDATION_KEY = random_password.revalidation_key.result
PAYLOAD_DEFAULT_USER_EMAIL = "[email protected]"
PAYLOAD_DEFAULT_USER_PASSWORD = random_password.payload_password.result
WEBSITES_PORT = local.payload_port
PAYLOAD_PORT = local.payload_port
AZURE_STORAGE_CONNECTION_STRING = var.storage_connection_string
Expand Down

0 comments on commit 2351e55

Please sign in to comment.