-
Notifications
You must be signed in to change notification settings - Fork 0
/
app.py
32 lines (23 loc) · 924 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
#!/usr/bin/env python3
import os
import aws_cdk as cdk
from database import AwsActivityDatabaseStack
from notification import AwsActivityNotificationStack
from login import AwsSignInActivityStack
app = cdk.App()
us_east_1 = cdk.Environment(region=os.environ["CDK_DEFAULT_REGION"], account=os.getenv('CDK_DEFAULT_ACCOUNT'))
# database
db_stack = AwsActivityDatabaseStack(app, 'aws-activity-db', env=us_east_1,
description='Tracking AWS activities for security compliance'
)
# notification
notification_stack = AwsActivityNotificationStack(app, 'aws-activity-notification', env=us_east_1,
description='Notify AWS activities for security compliance'
)
# sign-in activity
AwsSignInActivityStack(app, 'aws-sign-in-activity', env=us_east_1,
dynamodb_table=db_stack.table,
notification_topic=notification_stack.topic,
description='Tracking AWS sign-in activities for security compliance'
)
app.synth()