Skip to content

Commit

Permalink
Remove old RDS database (#2733)
Browse files Browse the repository at this point in the history
* remove old rds

* remove tei database and unused module
  • Loading branch information
kenoir authored Oct 18, 2024
1 parent 3b31c61 commit 88d3ebe
Show file tree
Hide file tree
Showing 8 changed files with 2 additions and 107 deletions.
3 changes: 2 additions & 1 deletion infrastructure/critical/modules/rds-serverless/variables.tf
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
variable "cluster_identifier" {
type = string
type = string
default = null
}

variable "database_name" {
Expand Down
22 changes: 0 additions & 22 deletions infrastructure/critical/modules/rds/main.tf

This file was deleted.

3 changes: 0 additions & 3 deletions infrastructure/critical/modules/rds/outputs.tf

This file was deleted.

9 changes: 0 additions & 9 deletions infrastructure/critical/modules/rds/secrets.tf

This file was deleted.

30 changes: 0 additions & 30 deletions infrastructure/critical/modules/rds/variables.tf

This file was deleted.

4 changes: 0 additions & 4 deletions infrastructure/critical/outputs.tf
Original file line number Diff line number Diff line change
@@ -1,9 +1,5 @@
# RDS

output "rds_cluster_id" {
value = module.identifiers_delta_rds_cluster.rds_cluster_id
}

output "rds_serverless_cluster_id" {
value = module.identifiers_serverless_rds_cluster.rds_cluster_id
}
Expand Down
20 changes: 0 additions & 20 deletions infrastructure/critical/rds_id_minter.tf
Original file line number Diff line number Diff line change
Expand Up @@ -46,25 +46,6 @@ resource "aws_security_group" "database_sg" {
}
}

module "identifiers_delta_rds_cluster" {
source = "./modules/rds"
cluster_identifier = "identifiers-delta-cluster"
database_name = "identifiers"
username = local.rds_username
password = local.rds_password

# This instance class provides us with 45 connections per instance.
instance_count = 1
instance_class = "db.t3.medium"

db_security_group_id = aws_security_group.database_sg.id
aws_db_subnet_group_name = aws_db_subnet_group.default.name

engine = "aurora-mysql"
db_parameter_group_name = "default.aurora-mysql5.7"
}

# This is the serverless RDS cluster that we will migrate to.
module "identifiers_serverless_rds_cluster" {
source = "./modules/rds-serverless"

Expand All @@ -76,7 +57,6 @@ module "identifiers_serverless_rds_cluster" {
db_security_group_id = aws_security_group.database_sg.id
aws_db_subnet_group_name = aws_db_subnet_group.default.name

# This is the snapshot from the last time we migrated the database.
snapshot_identifier = "aurora-mysql-v3-pre-migration-24-10-08"

engine_version = "8.0.mysql_aurora.3.07.1"
Expand Down
18 changes: 0 additions & 18 deletions tei_adapter/terraform/rds_id_extractor.tf
Original file line number Diff line number Diff line change
Expand Up @@ -46,24 +46,6 @@ resource "aws_security_group" "database_sg" {
}
}

module "tei_id_extractor_rds_cluster" {
source = "../../infrastructure/critical/modules/rds"
cluster_identifier = "tei-adapter-cluster"
database_name = "pathid"
username = local.rds_username
password = local.rds_password

# This instance class provides us with 45 connections per instance.
instance_count = 1
instance_class = "db.t3.small"

db_security_group_id = aws_security_group.database_sg.id
aws_db_subnet_group_name = aws_db_subnet_group.default.name

engine = "aurora-mysql"
db_parameter_group_name = aws_db_parameter_group.default.id
}

module "tei_id_extractor_rds_serverless_cluster" {
source = "../../infrastructure/critical/modules/rds-serverless"
cluster_identifier = "tei-adapter-cluster-serverless"
Expand Down

0 comments on commit 88d3ebe

Please sign in to comment.