Skip to content

Commit ed68c1e

Browse files
committed
fix conditions for rg
1 parent 377d28d commit ed68c1e

File tree

2 files changed

+3
-2
lines changed

2 files changed

+3
-2
lines changed

infra/main.tfvars.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,9 @@
11
{
2+
"resource_group_name": "${RESOURCE_GROUP_NAME}",
23
"location": "${AZURE_LOCATION}",
34
"use_billing_policy": "${USE_BILLING_POLICY:-false}",
45
"azd_environment_name": "${AZURE_ENV_NAME}",
5-
"resource_share_user": "${RESOURCE_SHARE_USER}",
6+
"resource_share_user": ${RESOURCE_SHARE_USER},
67
"deploy_github_runner": "${DEPLOY_GITHUB_RUNNER:-false}",
78
"enable_failover_github_runner": "${ENABLE_FAILOVER_GITHUB_RUNNER:-false}",
89
"github_runner_config": {

infra/variables.tf

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ variable "resource_group_name" {
1717
description = "The name of an existing resource group to deploy resources into. If not provided, a new resource group will be created."
1818

1919
validation {
20-
condition = var.resource_group_name == null || can(regex("^[a-zA-Z0-9._\\(\\)-]+$", var.resource_group_name))
20+
condition = var.resource_group_name == null || length(var.resource_group_name) == 0 || can(regex("^[a-zA-Z0-9._\\(\\)-]+$", var.resource_group_name))
2121
error_message = "Resource group name must contain only alphanumeric characters, periods, underscores, hyphens, and parentheses."
2222
}
2323
}

0 commit comments

Comments
 (0)