-
Notifications
You must be signed in to change notification settings - Fork 32
/
Copy pathapp.py
36 lines (26 loc) · 749 Bytes
/
app.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
#!/usr/bin/env python3
# -*- encoding: utf-8 -*-
# vim: tabstop=2 shiftwidth=2 softtabstop=2 expandtab
import os
from cdk_stacks import (
VpcStack,
DmsIAMRolesStack,
DMSServerlessAuroraMysqlToS3Stack
)
import aws_cdk as cdk
AWS_ENV = cdk.Environment(
account=os.getenv('CDK_DEFAULT_ACCOUNT'),
region=os.getenv('CDK_DEFAULT_REGION')
)
app = cdk.App()
vpc_stack = VpcStack(app, 'DMSAuroraMysqlToS3VPCStack',
env=AWS_ENV
)
dms_iam_permissions = DmsIAMRolesStack(app, 'DMSRequiredIAMRolesStack')
dms_iam_permissions.add_dependency(vpc_stack)
dms_task_stack = DMSServerlessAuroraMysqlToS3Stack(app, 'DMSServerlessAuroraMysqlToS3Stack',
vpc_stack.vpc,
env=AWS_ENV
)
dms_task_stack.add_dependency(dms_iam_permissions)
app.synth()