You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
27 lines
656 B
Python
27 lines
656 B
Python
#!/usr/bin/env python3
|
|
import os
|
|
import aws_cdk as cdk
|
|
from sfec2.sci_stack import SciInstancesStack
|
|
from sfec2.sci_stack import VpcBasisStack
|
|
|
|
app = cdk.App()
|
|
|
|
regionList = [
|
|
"us-east-1" , # Northern Virginia
|
|
"ap-southeast-1", # Singapore
|
|
"ap-southeast-2", # Sydney
|
|
"eu-west-1" , # Dublin, Ireland
|
|
"sa-east-1" # São Paulo, Brazil
|
|
]
|
|
|
|
i = 0
|
|
for region in regionList:
|
|
cdkEnv = cdk.Environment(
|
|
account=os.getenv('CDK_DEFAULT_ACCOUNT'),
|
|
region=region)
|
|
vpcStack = VpcBasisStack(app, f"net-{region}", env=cdkEnv )
|
|
SciInstancesStack(vpcStack, f"ec2-{i}", env=cdkEnv )
|
|
i = i + 1
|
|
|
|
app.synth()
|