diff --git a/modules/gcs/main.tf b/modules/gcs/main.tf index 19e2441da..d513cbf2c 100644 --- a/modules/gcs/main.tf +++ b/modules/gcs/main.tf @@ -18,7 +18,7 @@ locals { prefix = ( var.prefix == null || var.prefix == "" # keep "" for backward compatibility ? "" - : join("-", [var.prefix, lower(var.location), ""]) + : "${var.prefix}-" ) notification = try(var.notification_config.enabled, false) } diff --git a/tests/modules/gcs/test_plan.py b/tests/modules/gcs/test_plan.py index 79f86056d..04eaf58ea 100644 --- a/tests/modules/gcs/test_plan.py +++ b/tests/modules/gcs/test_plan.py @@ -31,7 +31,7 @@ def test_buckets(plan_runner): def test_prefix(plan_runner): "Test bucket name when prefix is set." _, resources = plan_runner(FIXTURES_DIR, prefix='foo') - assert resources[0]['values']['name'] == 'foo-eu-bucket-a' + assert resources[0]['values']['name'] == 'foo-bucket-a' def test_config_values(plan_runner):