Skip to content

Commit

Permalink
make sure db gets destroyed, try fix stack names
Browse files Browse the repository at this point in the history
  • Loading branch information
emileten committed Feb 22, 2024
1 parent c96cb1c commit 0d0f878
Showing 1 changed file with 6 additions and 4 deletions.
10 changes: 6 additions & 4 deletions integration_tests/cdk/app.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,8 @@
Stack,
aws_ec2,
aws_rds,
App
App,
RemovalPolicy
)
from constructs import Construct
from eoapi_cdk import (
Expand Down Expand Up @@ -86,7 +87,8 @@ def __init__(
subnet_type=aws_ec2.SubnetType.PUBLIC,
),
allocated_storage=app_config.db_allocated_storage,
instance_type=aws_ec2.InstanceType(app_config.db_instance_type)
instance_type=aws_ec2.InstanceType(app_config.db_instance_type),
removal_policy=RemovalPolicy.DESTROY
)

pgstac_db.db.connections.allow_default_port_from_any_ipv4()
Expand Down Expand Up @@ -136,11 +138,11 @@ def __init__(

app_config = build_app_config()

vpc_stack_id = f"{app_config.build_service_name('vpc')}".replace('/','')
vpc_stack_id = f"{app_config.project_id}-vpc"

vpc_stack = VpcStack(scope=app, app_config=app_config, id=vpc_stack_id)

pgstac_infra_stack_id = f"{app_config.build_service_name('pgstac')}".replace('/','')
pgstac_infra_stack_id = f"{app_config.project_id}-pgstac"

pgstac_infra_stack = pgStacInfraStack(
scope=app,
Expand Down

0 comments on commit 0d0f878

Please sign in to comment.