Skip to content

Commit

Permalink
Fix getting AWS region from data
Browse files Browse the repository at this point in the history
  • Loading branch information
klejejs committed Sep 26, 2024
1 parent 0c4ee70 commit 72cdd67
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion stun_server/region/ecs.tf
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
resource "aws_ecs_service" "stun-server" {
name = local.service_name
cluster = data.tfe_outputs.infrastructure.values[aws_region.current.name].ecs_cluster
cluster = data.tfe_outputs.infrastructure.values[data.aws_region.current.name].ecs_cluster
task_definition = module.stun_server.task_definition
desired_count = 1
deployment_minimum_healthy_percent = 100
Expand Down
2 changes: 1 addition & 1 deletion stun_server/region/module.tf
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ module "stun_server" {
service_name = local.service_name
container_image = "ghcr.io/home-assistant/stun"
container_version = var.image_tag
region = aws_region.current.name
region = data.aws_region.current.name
ecs_cpu = 2048
ecs_memory = 4096
container_definitions = {
Expand Down
2 changes: 1 addition & 1 deletion stun_server/region/network.tf
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
resource "aws_security_group" "stun_sg" {
vpc_id = data.tfe_outputs.infrastructure.values[aws_region.current.name].network_id
vpc_id = data.tfe_outputs.infrastructure.values[data.aws_region.current.name].network_id

egress {
from_port = 0
Expand Down

0 comments on commit 72cdd67

Please sign in to comment.