Skip to content
This repository has been archived by the owner on Jan 3, 2025. It is now read-only.

Commit

Permalink
add missing VAULT_APPLICATION variable
Browse files Browse the repository at this point in the history
  • Loading branch information
FinnIckler committed Oct 18, 2023
1 parent cedada6 commit 006f149
Show file tree
Hide file tree
Showing 5 changed files with 16 additions and 7 deletions.
1 change: 1 addition & 0 deletions env_config.rb
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@
mandatory :QUEUE_URL, :string
mandatory :WCA_HOST, :string
mandatory :REDIS_URL, :string
mandatory :VAULT_APPLICATION, :string
else
mandatory :LOCALSTACK_ENDPOINT, :string
# Have to be the same as in localstack to simulate authentication
Expand Down
12 changes: 8 additions & 4 deletions infra/handler/main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -20,9 +20,13 @@ locals {
name = "VAULT_ADDR"
value = var.vault_address
},
{
name = "VAULT_APPLICATION",
value = "wca-registration-production"
},
{
name = "REGISTRATION_LIVE_SITE",
value = true
value = "true"
},
{
name = "TASK_ROLE"
Expand Down Expand Up @@ -152,9 +156,9 @@ resource "aws_ecs_task_definition" "this" {
logConfiguration = {
logDriver = "awslogs"
options = {
awslogs-group = "${aws_cloudwatch_log_group.this.name}"
awslogs-region = "${var.region}"
awslogs-stream-prefix = "${var.name_prefix}"
awslogs-group = aws_cloudwatch_log_group.this.name
awslogs-region = var.region
awslogs-stream-prefix = var.name_prefix
}
}
environment = local.app_environment
Expand Down
6 changes: 5 additions & 1 deletion infra/staging/main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,11 @@ locals {
},
{
name = "REGISTRATION_LIVE_SITE",
value = false
value = "false"
},
{
name = "VAULT_APPLICATION",
value = "wca-registration-staging"
},
{
name = "HOST",
Expand Down
2 changes: 1 addition & 1 deletion infra/staging/variables.tf
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ variable "env" {
}

variable "host" {
type = string,
type = string
description = "The address of the service"
default = "staging.registration.worldcubeassociation.org"
}
Expand Down
2 changes: 1 addition & 1 deletion infra/worker/lambda.tf
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ data "aws_iam_policy_document" "lambda_policy" {
"dynamodb:DeleteItem",
"dynamodb:DescribeTable",
]
resources = [var.shared_resources.dynamo_registration_table, "${var.shared_resources.dynamo_registration_table}/*"]
resources = [var.shared_resources.dynamo_registration_table.arn, "${var.shared_resources.dynamo_registration_table.arn}/*"]
}
statement {
effect = "Allow"
Expand Down

0 comments on commit 006f149

Please sign in to comment.