Skip to content

njohnstone2/aws-watch

Repository files navigation

AWS Watch

A lambda function that monitors AWS Cloudtrail management events and publishes them to a slack channel

Example Cloudtrail message

Getting Started

  • setup a slack bot to receive the events
  • setup cloudtrail management events
  • build the lambda function
  • deploy to ECR

Testing locally

cd deploy/sam
cat >> dev.json << 'END'
{
  "Parameters": {
    "LOG_LEVEL": "DEBUG",
    "REGION": "<ENTER_AWS_REGION>"
  }
}
END
sam build 
sam local invoke -e test_events/ec2_sg.json -n dev.json

Deploy to AWS

cd deploy/sam
sam build
sam deploy

Terraform

cd deploy/terraform
terraform init
terraform plan -var-file variables/dev.tfvars 

About

No description, website, or topics provided.

Resources

License

Code of conduct

Stars

Watchers

Forks

Packages