changed default vpc definition

This commit is contained in:
Khalim Conn-Kowlessar 2023-07-10 13:41:41 +01:00
parent 4877db46f8
commit 63ba8ce5cb

View file

@ -30,14 +30,16 @@ data "aws_secretsmanager_secret_version" "db_credentials" {
}
# Default VPC
data "aws_default_vpc" "default" {}
data "aws_vpc" "default" {
default = true
}
# For MVP, we allow all inbound traffic to the DB - this will need to be changed later; we'll likely
# need to re-deploy the frontend to AWS so that it's within the same VPC as the DB
resource "aws_security_group" "allow_db" {
name = "allow_tls"
description = "Allow TLS inbound traffic"
vpc_id = data.aws_default_vpc.default.id
vpc_id = data.aws_vpc.default.id
ingress {
# TLS (change to whatever ports you need)