Skip to content

Commit

Permalink
Merge pull request #31 from chef-customers/better_notifications
Browse files Browse the repository at this point in the history
Adding SNS notifications for RDS and AutoScalingGroup
  • Loading branch information
rwc authored Jan 30, 2018
2 parents 26d63b2 + 45318d0 commit 7e157c5
Showing 1 changed file with 23 additions and 1 deletion.
24 changes: 23 additions & 1 deletion backendless_chef.yaml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
AWSTemplateFormatVersion: '2010-09-09'
Description: AWS Native Chef Server v3.2.0
Description: AWS Native Chef Server v3.3.0

Parameters:
# Required Parameters
Expand Down Expand Up @@ -299,6 +299,13 @@ Resources:
- !Ref ChefPJELB
MaxSize: '1'
MinSize: '1'
NotificationConfigurations:
- TopicARN: !Ref AlertNotificationTopic
NotificationTypes:
- autoscaling:EC2_INSTANCE_LAUNCH
- autoscaling:EC2_INSTANCE_LAUNCH_ERROR
- autoscaling:EC2_INSTANCE_TERMINATE
- autoscaling:EC2_INSTANCE_TERMINATE_ERROR
Tags:
- Key: Name
Value: !Sub ${AWS::StackName}-bootstrap-frontend
Expand All @@ -323,6 +330,13 @@ Resources:
- !Ref ChefTargetGroup
MaxSize: !Sub '${MaxFrontendInstances}'
MinSize: !Sub '${MinFrontendInstances}'
NotificationConfigurations:
- TopicARN: !Ref AlertNotificationTopic
NotificationTypes:
- autoscaling:EC2_INSTANCE_LAUNCH
- autoscaling:EC2_INSTANCE_LAUNCH_ERROR
- autoscaling:EC2_INSTANCE_TERMINATE
- autoscaling:EC2_INSTANCE_TERMINATE_ERROR
Tags:
- Key: Name
Value: !Sub ${AWS::StackName}-frontend
Expand Down Expand Up @@ -965,6 +979,14 @@ Resources:
- Key: X-Contact
Value: !Ref ContactEmail

RdsEventSubscription:
Type: AWS::RDS::EventSubscription
Properties:
SnsTopicArn: !Ref AlertNotificationTopic
SourceIds:
- !Ref DBPostgres
SourceType: db-instance

# ElasticSearch
#########################################################################################
ESSecurityGroup:
Expand Down

0 comments on commit 7e157c5

Please sign in to comment.