Skip to content

Commit

Permalink
move eCR metadata db variables to modules
Browse files Browse the repository at this point in the history
  • Loading branch information
BobanL committed Oct 22, 2024
1 parent 88ebb93 commit eeab1bb
Show file tree
Hide file tree
Showing 4 changed files with 21 additions and 13 deletions.
12 changes: 0 additions & 12 deletions terraform/implementation/ecs/_variable.tf
Original file line number Diff line number Diff line change
Expand Up @@ -70,15 +70,3 @@ variable "vpc_cidr" {
type = string
default = "176.24.0.0/16"
}

variable "ecr_viewer_database_type" {
description = "The SQL variant used for the eCR data tables"
type = string
default = "postgres"
}

variable "ecr_viewer_database_schema" {
description = "The database schema used for the eCR data tables"
type = string
default = "core"
}
2 changes: 1 addition & 1 deletion terraform/implementation/ecs/main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ module "ecs" {
owner = var.owner
project = var.project
tags = local.tags

# If intent is to pull from the phdi GHCR, set disable_ecr to true (default is false)
# disable_ecr = true
# If intent is to use the non-integrated viewer, set non_integrated_viewer to true (default is false)
Expand Down
8 changes: 8 additions & 0 deletions terraform/modules/ecs/_local.tf
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,14 @@ locals {
{
name = "NEXT_PUBLIC_BASEPATH",
value = var.ecr_viewer_basepath
},
{
name = "METADATA_DATABASE_SCHEMA",
value = var.ecr_viewer_metadata_database_schema
},
{
name = "METADATA_DATABASE_TYPE",
value = var.ecr_viewer_metadata_database_type
}
]
},
Expand Down
12 changes: 12 additions & 0 deletions terraform/modules/ecs/_variable.tf
Original file line number Diff line number Diff line change
Expand Up @@ -190,3 +190,15 @@ Iynom6unaheZpS4DFIh2w9UCAwEAAQ==
-----END PUBLIC KEY-----
EOT
}

variable "ecr_viewer_metadata_database_schema" {
description = "The database schema used for the eCR metadata tables"
type = string
default = "core"
}

variable "ecr_viewer_metadata_database_type" {
description = "The SQL variant used for the eCR metadata tables"
type = string
default = "postgres"
}

0 comments on commit eeab1bb

Please sign in to comment.