Skip to content

Commit

Permalink
Set max_allocated_storage var and switch to updated Terraform db module
Browse files Browse the repository at this point in the history
  • Loading branch information
KlaasH committed Jun 22, 2023
1 parent 911fdcb commit 25d9f42
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 2 deletions.
2 changes: 2 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,8 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0

### Changed

- Updated database Terraform module to use the 'max_allocated_storage' param [#1312](https://github.com/PublicMapping/districtbuilder/pull/1312)

### Fixed

## [1.19.1]
Expand Down
7 changes: 5 additions & 2 deletions deployment/terraform/database.tf
Original file line number Diff line number Diff line change
Expand Up @@ -75,14 +75,17 @@ resource "aws_db_parameter_group" "default" {
}

module "database" {
source = "github.com/azavea/terraform-aws-postgresql-rds?ref=3.0.0"
# TODO: go back to github.com/azavea/terraform-aws-postgresql-rds once it's updated
# (see https://github.com/azavea/terraform-aws-postgresql-rds/pull/48)
source = "github.com/KlaasH/terraform-aws-postgresql-rds?ref=max-allocated-storage"

vpc_id = module.vpc.id
allocated_storage = var.rds_allocated_storage
max_allocated_storage = var.rds_max_allocated_storage
engine_version = var.rds_engine_version
instance_type = var.rds_instance_type
storage_type = var.rds_storage_type
iops = var.rds_storage_type == "io1" ? var.rds_iops : null
iops = var.rds_iops
database_identifier = var.rds_database_identifier
database_name = var.rds_database_name
database_username = var.rds_database_username
Expand Down
5 changes: 5 additions & 0 deletions deployment/terraform/variables.tf
Original file line number Diff line number Diff line change
Expand Up @@ -58,6 +58,11 @@ variable "rds_allocated_storage" {
type = string
}

variable "rds_max_allocated_storage" {
default = 0
type = string
}

variable "rds_engine_version" {
default = "12.4"
type = string
Expand Down

0 comments on commit 25d9f42

Please sign in to comment.