Posts Slack notifications when an AWS Elastic Beanstalk managed update is applied to an environment
Notifies a slack channel when an AWS Elastic beanstalk managed platform update is applied to an environment.
Before installing anything to AWS, you will need to configure a "bot" in Slack to handle the posts for you. To do this:
- In Slack, choose Manage Apps -> Custom Integrations -> Bots
- Add a new bot configuration
- username: beanstalk-notifier
- Copy the API Token.
- Don't worry about other parameters - the notifier over-rides them anyway
- In Slack, upload a custom emoji and name it :elasticbeanstalk:
- You can use any image here...one is provided in the emoji folder of this project also
- Grab the latest Lambda function zip from Releases
- Create a new cloudformation stack using the template in the cfn folder
The stack asks for the function zip file location in S3, the slack API Key and the slack channel to post notifications to. Once the stack is created, a cloudwatch event is created to subscribe the lambda function to the UpdateEnvironment
elastic beanstalk call. The event is then further interrogated to see if it's an environment update.
You can also optionally provide a REST endpoint to post a notification to VictorOps. If you enter an endpoint here, an INFO
level notification will be sent to your VictorOps timeline as well as to Slack.