This SAM template provides a CloudFormation stack which deploys the infrastructure necessary for automated reachability assessment and notification using VPC Reachability Analyzer. Additionally, a sample Lambda function which detects security group changes, launches VPC Reachability Analyzer analyses, and notifies AWS administrators of any failed analyses is included.
- AWS Identity and Access Management
- Amazon EventBridge
- Amazon Simple Notification Service
- Amazon Virtual Private Cloud
- VPC Reachability Analyzer
- AWS CloudTrail
- AWS Lambda
- Clone this project to a local folder.
- Change directory to inside the project folder.
- Build the project using the SAM CLI in a terminal
sam build
- Deploy the project using the SAM CLI in a terminal
sam deploy -g --capablities CAPABILITY_NAMED_IAM
Options will be presented after executing the sam deploy
command. Options are summarized below.
## The name of the CloudFormation stack
Stack Name [sam-app]:
## The region you want to deploy in
AWS Region [us-east-1]:
## The name of the SNS topic from which to send automated reachability assessment notifications
Parameter SnsTopicName []:
## The network block for the VPC which will be created by the template (i.e. 172.16.0.0/24)
Parameter VPCCidrBlock []:
## A subnet block residing within the VPCCidrBlock. (i.e. 172.16.0.0/26)
Confirm changes before deploy [y/N]:
## SAM needs permission to be able to create roles to connect to the resources in your template
Allow SAM CLI IAM role creation [Y/n]:
## Save your choice for later deployments
Save arguments to samconfig.toml [Y/n]:
SAM will then deploy the AWS CloudFormation stack to your AWS account. The ouputs provided by the CloudFormation template will be helpful while working through the blog post.
- Open the CloudFormation console
- Locate a stack named reachability-analyzer
- Select the radio option next to it
- Select Delete
- Select Delete stack to confirm
This library is licensed under the MIT-0 License. See the LICENSE file.