-
Notifications
You must be signed in to change notification settings - Fork 0
/
system_b.yml
40 lines (36 loc) · 928 Bytes
/
system_b.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
AWSTemplateFormatVersion: '2010-09-09'
Description: System B
Resources:
Queue:
Type: AWS::SQS::Queue
# Properties:
# RedrivePolicy:
# deadLetterTargetArn: !GetAtt DLQueue.Arn
# maxReceiveCount: 3
# DLQueue:
# Type: AWS::SQS::Queue
SnsSubscription:
Type: AWS::SNS::Subscription
Properties:
Protocol: sqs
Endpoint: !GetAtt Queue.Arn
TopicArn: !ImportValue SystemASnsTopicArn
QueuePolycy:
Type: AWS::SQS::QueuePolicy
Properties:
PolicyDocument:
Version: 2012-10-17
Id: AllowSnsTopicToSendMessage
Statement:
- Sid: 1
Effect: Allow
Principal: "*"
Action:
- sqs:SendMessage
Resource: "*"
Condition:
ArnEquals:
aws:SourceArn:
!ImportValue SystemASnsTopicArn
Queues:
- !Ref Queue