/
root.yml
1111 lines (1020 loc) · 60.8 KB
/
root.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
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
# stacks/root.yml
# Generally this template is used to launch stacks from the bootstrapping
# CodePipeline. Primarily is is simply a wrapper around individial app- and
# service-specific templates, which get nested into this template and are
# launched when this one is. The CodePiple also passes in a template
# configuration file, which includes parameter values for this and all nested
# templates. This root template MUST define all parameters that are included in
# the config file. It can then pass along select values to nested stacks that
# require them.
AWSTemplateFormatVersion: "2010-09-09"
Description: >-
Launches stacks for a number of applications and services that are maintained
in separate templates. This stack is only intended to be launched once in a
given region, and launching more than one will likely fail. The stack can
operate in either Primary or Secondary mode, depending on its current role in
a multi-region setup.
Parameters:
# Optional
SharedAuroraMysqlEndpoint: { Type: AWS::SSM::Parameter::Value<String> }
SharedAuroraMysqlPort: { Type: String, Default: "3306" }
SharedAuroraPostgresqlEndpoint: { Type: AWS::SSM::Parameter::Value<String> }
SharedAuroraPostgresqlPort: { Type: String, Default: "3306" }
NewRelicApiKeyPrxLite: { Type: AWS::SSM::Parameter::Value<String>, Default: /prx/global/Spire/new-relic-lite-api-key }
AuthorizedKeys: { Type: AWS::SSM::Parameter::Value<List<String>>, Default: /prx/global/Spire/authorized-keys, NoEcho: true }
NestedChangeSetScrubbingResourcesState:
Type: String
Default: Disabled
AllowedValues:
- Enabled
- Disabled
# Required
SlackMessageRelayTopicArn: { Type: AWS::SSM::Parameter::Value<String>, Default: /prx/global/Spire/slack-message-relay-sns-topic-arn }
AwsOrganizationId: { Type: AWS::SSM::Parameter::Value<String>, Default: /prx/global/Spire/aws-organization-id }
# Parameter Overrides from the CodePipeline action
StorageStackName: { Type: String }
InfrastructureGitCommit: { Type: String }
Nonce: { Type: String }
TemplateUrlBase: { Type: String }
EnvironmentType:
Type: String
AllowedValues:
- Staging
- Production
EnvironmentTypeAbbreviation:
Type: String
AllowedValues:
- stag
- prod
Mappings:
# Each app should be given a listener rule priority prefix between 1 and 500.
# In app stacks, listener rule priorities are created by combining the
# prefix with exactly two more digits. This allows each app to have up to 99
# rules per listener.
#
# Higher-traffic apps should be given a higher priority (lower number) to
# reduce the number of rules evaluations needed for more common requests.
#
# The final rule priority values must be between 1 and 50000.
SharedAlbListenerRulePriorityMap:
Feeder: { prefix: 7 }
Cms: { prefix: 10 }
Exchange: { prefix: 13 }
Play: { prefix: 15 }
Augury: { prefix: 19 }
Id: { prefix: 24 }
Castle: { prefix: 26 } # Dovetail Castle
Networks: { prefix: 28 }
Remix: { prefix: 29 }
Publish: { prefix: 31 }
Metrics: { prefix: 36 }
TheCount: { prefix: 42 }
TheCastle: { prefix: 50 } # Legacy Castle
Styleguide: { prefix: 65 }
Iframely: { prefix: 73 }
Wfmt: { prefix: 77 }
TheWorldWebsite: { prefix: 82 }
SharedVpcCidrBlockMap:
# must be a /16 private network
us-east-1:
Staging: 10.30.0.0/16
Production: 172.30.0.0/16
us-west-2:
Staging: 10.33.0.0/16
Production: 172.23.0.0/16
RegionModeMap:
us-east-1:
Staging: Primary
Production: Primary
us-west-2:
Staging: Secondary
Production: Secondary
Conditions:
IsUsEast1: !Equals [!Ref "AWS::Region", us-east-1]
HasSharedAuroraMysqlEndpoint: !Not [!Equals [!Ref SharedAuroraMysqlEndpoint, ""]]
HasSharedAuroraPostgresqlEndpoint: !Not [!Equals [!Ref SharedAuroraPostgresqlEndpoint, ""]]
HasAllSharedAuroraEndpoints: !And [!Condition HasSharedAuroraMysqlEndpoint, !Condition HasSharedAuroraPostgresqlEndpoint]
CreateDatabaseDependentResources: !Condition HasAllSharedAuroraEndpoints
# Application stacks require external MySQL/PostgreSQL databases
CreateApplicationStacks: !Condition CreateDatabaseDependentResources
# Dashboard requires that application stacks have been created
CreateDashboardsStack: !Condition CreateApplicationStacks
Resources:
Constants2:
Type: AWS::CloudFormation::Stack
DeletionPolicy: Delete
UpdateReplacePolicy: Delete
Properties:
Parameters:
EnvironmentType: !Ref EnvironmentType
RootStackId: !Ref AWS::StackId
RootStackName: !Ref AWS::StackName
NestedChangeSetScrubbingResourcesState: !Ref NestedChangeSetScrubbingResourcesState
PorterStateMachineArn: !Sub /prx/${EnvironmentTypeAbbreviation}/Spire/${AWS::Region}/porter-state-machine-arn
DeploymentPackageBucketName:
Fn::ImportValue: !Sub ${StorageStackName}-InfrastructureApplicationCodeBucket
Tags:
- { Key: prx:meta:tagging-version, Value: "2021-04-07" }
- { Key: prx:cloudformation:stack-name, Value: !Ref AWS::StackName }
- { Key: prx:cloudformation:stack-id, Value: !Ref AWS::StackId }
- { Key: prx:cloudformation:root-stack-name, Value: !Ref AWS::StackName }
- { Key: prx:cloudformation:root-stack-id, Value: !Ref AWS::StackId }
- { Key: prx:ops:environment, Value: !Ref EnvironmentType }
- { Key: prx:dev:application, Value: Infrastructure }
TemplateURL: !Sub ${TemplateUrlBase}/spire/templates/constants.yml
TimeoutInMinutes: 5
CustomResourcesStack:
Type: AWS::CloudFormation::Stack
DeletionPolicy: Delete
UpdateReplacePolicy: Delete
Properties:
Parameters:
StorageStackName: !Ref StorageStackName
EnvironmentType: !Ref EnvironmentType
EnvironmentTypeAbbreviation: !Ref EnvironmentTypeAbbreviation
RootStackName: !Ref AWS::StackName
RootStackId: !Ref AWS::StackId
NestedChangeSetScrubbingResourcesState: !Ref NestedChangeSetScrubbingResourcesState
Tags:
- { Key: prx:meta:tagging-version, Value: "2021-04-07" }
- { Key: prx:cloudformation:stack-name, Value: !Ref AWS::StackName }
- { Key: prx:cloudformation:stack-id, Value: !Ref AWS::StackId }
- { Key: prx:cloudformation:root-stack-name, Value: !Ref AWS::StackName }
- { Key: prx:cloudformation:root-stack-id, Value: !Ref AWS::StackId }
- { Key: prx:ops:environment, Value: !Ref EnvironmentType }
- { Key: prx:dev:application, Value: Infrastructure }
TemplateURL: !Sub ${TemplateUrlBase}/spire/templates/custom-resources.yml
TimeoutInMinutes: 5
# TODO This is failing in us-west-2; "duplicate key" error
ResourceGroupsStack:
Type: AWS::CloudFormation::Stack
DeletionPolicy: Delete
UpdateReplacePolicy: Delete
Condition: IsUsEast1
Properties:
Parameters:
RootStackName: !Ref AWS::StackName
RootStackId: !Ref AWS::StackId
EnvironmentType: !Ref EnvironmentType
NestedChangeSetScrubbingResourcesState: !Ref NestedChangeSetScrubbingResourcesState
Tags:
- { Key: prx:meta:tagging-version, Value: "2021-04-07" }
- { Key: prx:cloudformation:stack-name, Value: !Ref AWS::StackName }
- { Key: prx:cloudformation:stack-id, Value: !Ref AWS::StackId }
- { Key: prx:cloudformation:root-stack-name, Value: !Ref AWS::StackName }
- { Key: prx:cloudformation:root-stack-id, Value: !Ref AWS::StackId }
- { Key: prx:ops:environment, Value: !Ref EnvironmentType }
- { Key: prx:dev:application, Value: Common }
TemplateURL: !Sub ${TemplateUrlBase}/spire/templates/resource-groups.yml
TimeoutInMinutes: 10
SharedGlueDatabaseStack:
Type: AWS::CloudFormation::Stack
DeletionPolicy: Delete
UpdateReplacePolicy: Delete
Properties:
Parameters:
EnvironmentType: !Ref EnvironmentType
RootStackName: !Ref AWS::StackName
NestedChangeSetScrubbingResourcesState: !Ref NestedChangeSetScrubbingResourcesState
Tags:
- { Key: prx:meta:tagging-version, Value: "2021-04-07" }
- { Key: prx:cloudformation:stack-name, Value: !Ref AWS::StackName }
- { Key: prx:cloudformation:stack-id, Value: !Ref AWS::StackId }
- { Key: prx:cloudformation:root-stack-name, Value: !Ref AWS::StackName }
- { Key: prx:cloudformation:root-stack-id, Value: !Ref AWS::StackId }
- { Key: prx:ops:environment, Value: !Ref EnvironmentType }
- { Key: prx:dev:application, Value: Common }
TemplateURL: !Sub ${TemplateUrlBase}/spire/templates/shared-glue-database.yml
TimeoutInMinutes: 10
SharedAnnounceStack:
Type: AWS::CloudFormation::Stack
DeletionPolicy: Delete
UpdateReplacePolicy: Delete
Properties:
Parameters:
RootStackName: !Ref AWS::StackName
RootStackId: !Ref AWS::StackId
EnvironmentType: !Ref EnvironmentType
EnvironmentTypeAbbreviation: !Ref EnvironmentTypeAbbreviation
NestedChangeSetScrubbingResourcesState: !Ref NestedChangeSetScrubbingResourcesState
HashStringServiceToken: !GetAtt CustomResourcesStack.Outputs.HashStringServiceToken
Tags:
- { Key: prx:meta:tagging-version, Value: "2021-04-07" }
- { Key: prx:cloudformation:stack-name, Value: !Ref AWS::StackName }
- { Key: prx:cloudformation:stack-id, Value: !Ref AWS::StackId }
- { Key: prx:cloudformation:root-stack-name, Value: !Ref AWS::StackName }
- { Key: prx:cloudformation:root-stack-id, Value: !Ref AWS::StackId }
- { Key: prx:ops:environment, Value: !Ref EnvironmentType }
- { Key: prx:dev:application, Value: Common }
TemplateURL: !Sub ${TemplateUrlBase}/spire/templates/shared-announce.yml
TimeoutInMinutes: 10
SharedDovetailKinesisStack:
Type: AWS::CloudFormation::Stack
DeletionPolicy: Delete
UpdateReplacePolicy: Delete
Properties:
Parameters:
RootStackName: !Ref AWS::StackName
RootStackId: !Ref AWS::StackId
EnvironmentType: !Ref EnvironmentType
AwsOrganizationId: !Ref AwsOrganizationId
NestedChangeSetScrubbingResourcesState: !Ref NestedChangeSetScrubbingResourcesState
Tags:
- { Key: prx:meta:tagging-version, Value: "2021-04-07" }
- { Key: prx:cloudformation:stack-name, Value: !Ref AWS::StackName }
- { Key: prx:cloudformation:stack-id, Value: !Ref AWS::StackId }
- { Key: prx:cloudformation:root-stack-name, Value: !Ref AWS::StackName }
- { Key: prx:cloudformation:root-stack-id, Value: !Ref AWS::StackId }
- { Key: prx:ops:environment, Value: !Ref EnvironmentType }
- { Key: prx:dev:application, Value: Common }
TemplateURL: !Sub ${TemplateUrlBase}/spire/templates/shared-dovetail-kinesis.yml
TimeoutInMinutes: 60
SharedEcsClusterStack:
Type: AWS::CloudFormation::Stack
DeletionPolicy: Delete
UpdateReplacePolicy: Delete
Properties:
Parameters:
EnvironmentType: !Ref EnvironmentType
RootStackName: !Ref AWS::StackName
RootStackId: !Ref AWS::StackName
NestedChangeSetScrubbingResourcesState: !Ref NestedChangeSetScrubbingResourcesState
Tags:
- { Key: prx:meta:tagging-version, Value: "2021-04-07" }
- { Key: prx:cloudformation:stack-name, Value: !Ref AWS::StackName }
- { Key: prx:cloudformation:stack-id, Value: !Ref AWS::StackId }
- { Key: prx:cloudformation:root-stack-name, Value: !Ref AWS::StackName }
- { Key: prx:cloudformation:root-stack-id, Value: !Ref AWS::StackId }
- { Key: prx:ops:environment, Value: !Ref EnvironmentType }
- { Key: prx:dev:application, Value: Common }
TemplateURL: !Sub ${TemplateUrlBase}/spire/templates/shared-ecs/ecs-cluster.yml
TimeoutInMinutes: 20
SharedVpcStack:
Type: AWS::CloudFormation::Stack
DeletionPolicy: Delete
UpdateReplacePolicy: Delete
Properties:
Parameters:
AvailabilityZoneSelectorServiceToken: !GetAtt CustomResourcesStack.Outputs.AvailabilityZoneSelectorServiceToken
EnvironmentType: !Ref EnvironmentType
RootStackName: !Ref AWS::StackName
RootStackId: !Ref AWS::StackId
NestedChangeSetScrubbingResourcesState: !Ref NestedChangeSetScrubbingResourcesState
TemplateUrlPrefix: !Sub ${TemplateUrlBase}/spire/templates/shared-vpc
Ec2ResourceTaggerServiceToken: !GetAtt CustomResourcesStack.Outputs.Ec2ResourceTaggerServiceToken
SharedVpcCidrBlock: !FindInMap [SharedVpcCidrBlockMap, !Ref "AWS::Region", !Ref EnvironmentType]
Tags:
- { Key: prx:meta:tagging-version, Value: "2021-04-07" }
- { Key: prx:cloudformation:stack-name, Value: !Ref AWS::StackName }
- { Key: prx:cloudformation:stack-id, Value: !Ref AWS::StackId }
- { Key: prx:cloudformation:root-stack-name, Value: !Ref AWS::StackName }
- { Key: prx:cloudformation:root-stack-id, Value: !Ref AWS::StackId }
- { Key: prx:ops:environment, Value: !Ref EnvironmentType }
- { Key: prx:dev:application, Value: Common }
TemplateURL: !Sub ${TemplateUrlBase}/spire/templates/shared-vpc.yml
TimeoutInMinutes: 20
# Requires VPC
SharedResourceShareStack:
Type: AWS::CloudFormation::Stack
DeletionPolicy: Delete
UpdateReplacePolicy: Delete
Properties:
Parameters:
EnvironmentType: !Ref EnvironmentType
RootStackName: !Ref AWS::StackName
RootStackId: !Ref AWS::StackId
NestedChangeSetScrubbingResourcesState: !Ref NestedChangeSetScrubbingResourcesState
SharedResourceSharePrincipals: !Sub /prx/${EnvironmentTypeAbbreviation}/Spire/Shared_Resource_Share/principals
VpcPrivateSubnet1: !GetAtt SharedVpcStack.Outputs.PrivateSubnet1Id
VpcPrivateSubnet2: !GetAtt SharedVpcStack.Outputs.PrivateSubnet2Id
VpcPrivateSubnet3: !GetAtt SharedVpcStack.Outputs.PrivateSubnet3Id
Tags:
- { Key: prx:meta:tagging-version, Value: "2021-04-07" }
- { Key: prx:cloudformation:stack-name, Value: !Ref AWS::StackName }
- { Key: prx:cloudformation:stack-id, Value: !Ref AWS::StackId }
- { Key: prx:cloudformation:root-stack-name, Value: !Ref AWS::StackName }
- { Key: prx:cloudformation:root-stack-id, Value: !Ref AWS::StackId }
- { Key: prx:ops:environment, Value: !Ref EnvironmentType }
- { Key: prx:dev:application, Value: Common }
TemplateURL: !Sub ${TemplateUrlBase}/spire/templates/shared-resource-share.yml
TimeoutInMinutes: 20
# Requires VPC
SharedDatabaseSecurityGroupsStack:
Type: AWS::CloudFormation::Stack
DeletionPolicy: Delete
UpdateReplacePolicy: Delete
Properties:
Parameters:
EnvironmentType: !Ref EnvironmentType
RootStackName: !Ref AWS::StackName
RootStackId: !Ref AWS::StackId
VpcId: !GetAtt SharedVpcStack.Outputs.VpcId
NestedChangeSetScrubbingResourcesState: !Ref NestedChangeSetScrubbingResourcesState
SharedVpcCidrBlock: !GetAtt SharedVpcStack.Outputs.VpcCidrBlock
SharedAuroraMysqlPort: !Ref SharedAuroraMysqlPort
SharedAuroraPostgresqlPort: !Ref SharedAuroraPostgresqlPort
Tags:
- { Key: prx:meta:tagging-version, Value: "2021-04-07" }
- { Key: prx:cloudformation:stack-name, Value: !Ref AWS::StackName }
- { Key: prx:cloudformation:stack-id, Value: !Ref AWS::StackId }
- { Key: prx:cloudformation:root-stack-name, Value: !Ref AWS::StackName }
- { Key: prx:cloudformation:root-stack-id, Value: !Ref AWS::StackId }
- { Key: prx:ops:environment, Value: !Ref EnvironmentType }
- { Key: prx:dev:application, Value: Common }
TemplateURL: !Sub ${TemplateUrlBase}/spire/templates/shared-db-sg.yml
TimeoutInMinutes: 20
# Requires VPC and shared Glue DB
SharedAlbStack:
Type: AWS::CloudFormation::Stack
DeletionPolicy: Delete
UpdateReplacePolicy: Delete
Properties:
Parameters:
EnvironmentType: !Ref EnvironmentType
RootStackName: !Ref AWS::StackName
RootStackId: !Ref AWS::StackName
EnvironmentTypeAbbreviation: !Ref EnvironmentTypeAbbreviation
NestedChangeSetScrubbingResourcesState: !Ref NestedChangeSetScrubbingResourcesState
VpcId: !GetAtt SharedVpcStack.Outputs.VpcId
VpcPublicSubnet1Id: !GetAtt SharedVpcStack.Outputs.PublicSubnet1Id
VpcPublicSubnet2Id: !GetAtt SharedVpcStack.Outputs.PublicSubnet2Id
VpcPublicSubnet3Id: !GetAtt SharedVpcStack.Outputs.PublicSubnet3Id
CloudWatchAlarmTaggerServiceToken: !GetAtt CustomResourcesStack.Outputs.CloudWatchAlarmTaggerServiceToken
SharedGlueDatabaseName: !GetAtt SharedGlueDatabaseStack.Outputs.SharedGlueDatabaseName
LatencyGroupDomain: !Sub spire-shared-alb-latency-group.${EnvironmentTypeAbbreviation}.prx.tech
Tags:
- { Key: prx:meta:tagging-version, Value: "2021-04-07" }
- { Key: prx:cloudformation:stack-name, Value: !Ref AWS::StackName }
- { Key: prx:cloudformation:stack-id, Value: !Ref AWS::StackId }
- { Key: prx:cloudformation:root-stack-name, Value: !Ref AWS::StackName }
- { Key: prx:cloudformation:root-stack-id, Value: !Ref AWS::StackId }
- { Key: prx:ops:environment, Value: !Ref EnvironmentType }
- { Key: prx:dev:application, Value: Common }
TemplateURL: !Sub ${TemplateUrlBase}/spire/templates/shared-alb.yml
TimeoutInMinutes: 40
# Requires VPC and ALB
SharedEcsAsgSecurityGroupStack:
Type: AWS::CloudFormation::Stack
DeletionPolicy: Delete
UpdateReplacePolicy: Delete
Properties:
Parameters:
EnvironmentType: !Ref EnvironmentType
RootStackName: !Ref AWS::StackName
RootStackId: !Ref AWS::StackName
NestedChangeSetScrubbingResourcesState: !Ref NestedChangeSetScrubbingResourcesState
VpcId: !GetAtt SharedVpcStack.Outputs.VpcId
LoadBalancerSecurityGroupId: !GetAtt SharedAlbStack.Outputs.LoadBalancerSecurityGroupId
Tags:
- { Key: prx:meta:tagging-version, Value: "2021-04-07" }
- { Key: prx:cloudformation:stack-name, Value: !Ref AWS::StackName }
- { Key: prx:cloudformation:stack-id, Value: !Ref AWS::StackId }
- { Key: prx:cloudformation:root-stack-name, Value: !Ref AWS::StackName }
- { Key: prx:cloudformation:root-stack-id, Value: !Ref AWS::StackId }
- { Key: prx:ops:environment, Value: !Ref EnvironmentType }
- { Key: prx:dev:application, Value: Common }
TemplateURL: !Sub ${TemplateUrlBase}/spire/templates/shared-ecs/asg-sg.yml
TimeoutInMinutes: 20
# Requires VPC, ALB, and more
SharedEcsAsgStack:
Type: AWS::CloudFormation::Stack
DeletionPolicy: Delete
UpdateReplacePolicy: Delete
Properties:
Parameters:
EnvironmentType: !Ref EnvironmentType
EnvironmentTypeAbbreviation: !Ref EnvironmentTypeAbbreviation
RegionMode: !FindInMap [RegionModeMap, !Ref "AWS::Region", !Ref EnvironmentType]
RootStackName: !Ref AWS::StackName
RootStackId: !Ref AWS::StackName
NestedChangeSetScrubbingResourcesState: !Ref NestedChangeSetScrubbingResourcesState
SlackMessageRelaySnsTopicArn: !Ref SlackMessageRelayTopicArn
AuthorizedKeys: !Join [",", !Ref AuthorizedKeys]
VpcPublicSubnet1Id: !GetAtt SharedVpcStack.Outputs.PublicSubnet1Id
VpcPublicSubnet2Id: !GetAtt SharedVpcStack.Outputs.PublicSubnet2Id
VpcPublicSubnet3Id: !GetAtt SharedVpcStack.Outputs.PublicSubnet3Id
EcsClusterName: !GetAtt SharedEcsClusterStack.Outputs.EcsClusterName
SharedEcsAsgInstanceSecurityGroupId: !GetAtt SharedEcsAsgSecurityGroupStack.Outputs.InstanceSecurityGroupId
LoadBalancerSecurityGroupId: !GetAtt SharedAlbStack.Outputs.LoadBalancerSecurityGroupId
SharedMysqlClientSecurityGroupId: !GetAtt SharedDatabaseSecurityGroupsStack.Outputs.SharedMysqlClientSecurityGroupId
SharedPostgresqlClientSecurityGroupId: !GetAtt SharedDatabaseSecurityGroupsStack.Outputs.SharedPostgresqlClientSecurityGroupId
SharedRedisClientSecurityGroupId: !GetAtt SharedRedisSecurityGroupStack.Outputs.ClientSecurityGroupId
EcsLaunchEndpointsAccessSecurityGroupId: !GetAtt SharedVpcStack.Outputs.EcsLaunchEndpointsAccessSecurityGroupId
KmsEndpointAccessSecurityGroupId: !GetAtt SharedVpcStack.Outputs.KmsEndpointAccessSecurityGroupId
SharedRedisReplicationGroupEndpointAddress: !GetAtt SharedRedisStack.Outputs.ReplicationGroupEndpointAddress
SharedRedisReplicationGroupEndpointPort: !GetAtt SharedRedisStack.Outputs.ReplicationGroupEndpointPort
CloudWatchAlarmTaggerServiceToken: !GetAtt CustomResourcesStack.Outputs.CloudWatchAlarmTaggerServiceToken
Tags:
- { Key: prx:meta:tagging-version, Value: "2021-04-07" }
- { Key: prx:cloudformation:stack-name, Value: !Ref AWS::StackName }
- { Key: prx:cloudformation:stack-id, Value: !Ref AWS::StackId }
- { Key: prx:cloudformation:root-stack-name, Value: !Ref AWS::StackName }
- { Key: prx:cloudformation:root-stack-id, Value: !Ref AWS::StackId }
- { Key: prx:ops:environment, Value: !Ref EnvironmentType }
- { Key: prx:dev:application, Value: Common }
TemplateURL: !Sub ${TemplateUrlBase}/spire/templates/shared-ecs/asg.yml
TimeoutInMinutes: 1440
# # Requires database and ECS/ASG security groups
# EicEndpoints:
# Type: AWS::CloudFormation::Stack
# UpdateReplacePolicy: Delete
# DeletionPolicy: Delete
# Properties:
# Parameters:
# EnvironmentType: !Ref EnvironmentType
# RootStackName: !Ref AWS::StackName
# RootStackId: !Ref AWS::StackId
# NestedChangeSetScrubbingResourcesState: !Ref NestedChangeSetScrubbingResourcesState
# PrivateSubnet1Id: !GetAtt SharedVpcStack.Outputs.PrivateSubnet1Id
# SharedMysqlClientSecurityGroupId: !GetAtt SharedDatabaseSecurityGroupsStack.Outputs.SharedMysqlClientSecurityGroupId
# SharedPostgresqlClientSecurityGroupId: !GetAtt SharedDatabaseSecurityGroupsStack.Outputs.SharedPostgresqlClientSecurityGroupId
# Tags:
# - { Key: prx:meta:tagging-version, Value: "2021-04-07" }
# - { Key: prx:cloudformation:stack-name, Value: !Ref AWS::StackName }
# - { Key: prx:cloudformation:stack-id, Value: !Ref AWS::StackId }
# - { Key: prx:cloudformation:root-stack-name, Value: !Ref AWS::StackName }
# - { Key: prx:cloudformation:root-stack-id, Value: !Ref AWS::StackId }
# - { Key: prx:ops:environment, Value: !Ref EnvironmentType }
# - { Key: prx:dev:application, Value: Common }
# TemplateURL: !Sub ${TemplateUrlBase}/spire/templates/eic-endpoints.yml
# TimeoutInMinutes: 20
# Requires VPC and ECS ASG SG
SharedMemcachedStack:
Type: AWS::CloudFormation::Stack
DeletionPolicy: Delete
UpdateReplacePolicy: Delete
Properties:
Parameters:
VpcId: !GetAtt SharedVpcStack.Outputs.VpcId
VpcPrivateSubnet1Id: !GetAtt SharedVpcStack.Outputs.PrivateSubnet1Id
VpcPrivateSubnet2Id: !GetAtt SharedVpcStack.Outputs.PrivateSubnet2Id
VpcPrivateSubnet3Id: !GetAtt SharedVpcStack.Outputs.PrivateSubnet3Id
RootStackId: !Ref AWS::StackId
RootStackName: !Ref AWS::StackName
NestedChangeSetScrubbingResourcesState: !Ref NestedChangeSetScrubbingResourcesState
EnvironmentType: !Ref EnvironmentType
EnvironmentTypeAbbreviation: !Ref EnvironmentTypeAbbreviation
CloudWatchAlarmTaggerServiceToken: !GetAtt CustomResourcesStack.Outputs.CloudWatchAlarmTaggerServiceToken
SourceSecurityGroupId1: !GetAtt SharedEcsAsgSecurityGroupStack.Outputs.InstanceSecurityGroupId
StagingInstanceType: cache.t4g.micro
ProductionInstanceType: cache.t4g.small
Tags:
- { Key: prx:meta:tagging-version, Value: "2021-04-07" }
- { Key: prx:cloudformation:stack-name, Value: !Ref AWS::StackName }
- { Key: prx:cloudformation:stack-id, Value: !Ref AWS::StackId }
- { Key: prx:cloudformation:root-stack-name, Value: !Ref AWS::StackName }
- { Key: prx:cloudformation:root-stack-id, Value: !Ref AWS::StackId }
- { Key: prx:ops:environment, Value: !Ref EnvironmentType }
- { Key: prx:dev:application, Value: Common }
TemplateURL: !Sub ${TemplateUrlBase}/spire/templates/shared-memcached.yml
TimeoutInMinutes: 40
# Requires VPC and ECS ASG SG
SharedAppRedisStack:
Type: AWS::CloudFormation::Stack
DeletionPolicy: Delete
UpdateReplacePolicy: Delete
Properties:
Parameters:
EnvironmentType: !Ref EnvironmentType
RegionMode: !FindInMap [RegionModeMap, !Ref AWS::Region, !Ref EnvironmentType]
RootStackId: !Ref AWS::StackId
RootStackName: !Ref AWS::StackName
NestedChangeSetScrubbingResourcesState: !Ref NestedChangeSetScrubbingResourcesState
SourceSecurityGroupId1: !GetAtt SharedEcsAsgSecurityGroupStack.Outputs.InstanceSecurityGroupId
VpcId: !GetAtt SharedVpcStack.Outputs.VpcId
VpcPrivateSubnet1Id: !GetAtt SharedVpcStack.Outputs.PrivateSubnet1Id
VpcPrivateSubnet2Id: !GetAtt SharedVpcStack.Outputs.PrivateSubnet2Id
VpcPrivateSubnet3Id: !GetAtt SharedVpcStack.Outputs.PrivateSubnet3Id
Tags:
- { Key: prx:meta:tagging-version, Value: "2021-04-07" }
- { Key: prx:cloudformation:stack-name, Value: !Ref AWS::StackName }
- { Key: prx:cloudformation:stack-id, Value: !Ref AWS::StackId }
- { Key: prx:cloudformation:root-stack-name, Value: !Ref AWS::StackName }
- { Key: prx:cloudformation:root-stack-id, Value: !Ref AWS::StackId }
- { Key: prx:ops:environment, Value: !Ref EnvironmentType }
- { Key: prx:dev:application, Value: Common }
TemplateURL: !Sub ${TemplateUrlBase}/spire/templates/shared-app-redis.yml
TimeoutInMinutes: 40
# Requires VPC
SharedRedisSecurityGroupStack:
Type: AWS::CloudFormation::Stack
DeletionPolicy: Delete
UpdateReplacePolicy: Delete
Properties:
Parameters:
EnvironmentType: !Ref EnvironmentType
RootStackName: !Ref AWS::StackName
RootStackId: !Ref AWS::StackName
NestedChangeSetScrubbingResourcesState: !Ref NestedChangeSetScrubbingResourcesState
VpcId: !GetAtt SharedVpcStack.Outputs.VpcId
Tags:
- { Key: prx:meta:tagging-version, Value: "2021-04-07" }
- { Key: prx:cloudformation:stack-name, Value: !Ref AWS::StackName }
- { Key: prx:cloudformation:stack-id, Value: !Ref AWS::StackId }
- { Key: prx:cloudformation:root-stack-name, Value: !Ref AWS::StackName }
- { Key: prx:cloudformation:root-stack-id, Value: !Ref AWS::StackId }
- { Key: prx:ops:environment, Value: !Ref EnvironmentType }
- { Key: prx:dev:application, Value: Common }
TemplateURL: !Sub ${TemplateUrlBase}/spire/templates/shared-redis/security-groups.yml
TimeoutInMinutes: 20
# Requires VPC and Redis SG
# This would more accurately be named "SharedDovetailRedisStack"
SharedRedisStack:
Type: AWS::CloudFormation::Stack
DeletionPolicy: Delete
UpdateReplacePolicy: Delete
Properties:
Parameters:
RootStackName: !Ref AWS::StackName
RootStackId: !Ref AWS::StackId
EnvironmentType: !Ref EnvironmentType
EnvironmentTypeAbbreviation: !Ref EnvironmentTypeAbbreviation
RegionMode: !FindInMap [RegionModeMap, !Ref "AWS::Region", !Ref EnvironmentType]
NestedChangeSetScrubbingResourcesState: !Ref NestedChangeSetScrubbingResourcesState
VpcPrivateSubnet1Id: !GetAtt SharedVpcStack.Outputs.PrivateSubnet1Id
VpcPrivateSubnet2Id: !GetAtt SharedVpcStack.Outputs.PrivateSubnet2Id
VpcPrivateSubnet3Id: !GetAtt SharedVpcStack.Outputs.PrivateSubnet3Id
CloudWatchAlarmTaggerServiceToken: !GetAtt CustomResourcesStack.Outputs.CloudWatchAlarmTaggerServiceToken
SharedRedisClusterSecurityGroupId: !GetAtt SharedRedisSecurityGroupStack.Outputs.ClusterSecurityGroupId
Tags:
- { Key: prx:meta:tagging-version, Value: "2021-04-07" }
- { Key: prx:cloudformation:stack-name, Value: !Ref AWS::StackName }
- { Key: prx:cloudformation:stack-id, Value: !Ref AWS::StackId }
- { Key: prx:cloudformation:root-stack-name, Value: !Ref AWS::StackName }
- { Key: prx:cloudformation:root-stack-id, Value: !Ref AWS::StackId }
- { Key: prx:ops:environment, Value: !Ref EnvironmentType }
- { Key: prx:dev:application, Value: Common }
TemplateURL: !Sub ${TemplateUrlBase}/spire/templates/shared-redis/cluster.yml
TimeoutInMinutes: 60
# Requires everything above, AND external MySQL/PostgreSQL databases
Apps100AStack:
Type: AWS::CloudFormation::Stack
Condition: CreateApplicationStacks
DeletionPolicy: Delete
UpdateReplacePolicy: Delete
Properties:
Parameters:
TemplateUrlPrefix: !Sub ${TemplateUrlBase}/spire/templates/apps
AlbFullName: !GetAtt SharedAlbStack.Outputs.AlbFullName
AlbHttpsListenerArn: !GetAtt SharedAlbStack.Outputs.HttpsListenerArn
EcsClusterArn: !GetAtt SharedEcsClusterStack.Outputs.EcsClusterArn
VpcId: !GetAtt SharedVpcStack.Outputs.VpcId
NewRelicApiKeyPrxLite: !Ref NewRelicApiKeyPrxLite
AwsOrganizationId: !Ref AwsOrganizationId
EnvironmentType: !Ref EnvironmentType
EnvironmentTypeAbbreviation: !Ref EnvironmentTypeAbbreviation
EnvironmentTypeLowercase: !GetAtt Constants2.Outputs.EnvironmentTypeLowercase
RegionMode: !FindInMap [RegionModeMap, !Ref "AWS::Region", !Ref EnvironmentType]
RootStackName: !Ref AWS::StackName
RootStackId: !Ref AWS::StackId
NestedChangeSetScrubbingResourcesState: !Ref NestedChangeSetScrubbingResourcesState
VpcPrivateSubnet1Id: !GetAtt SharedVpcStack.Outputs.PrivateSubnet1Id
VpcPrivateSubnet2Id: !GetAtt SharedVpcStack.Outputs.PrivateSubnet2Id
VpcPrivateSubnet3Id: !GetAtt SharedVpcStack.Outputs.PrivateSubnet3Id
KinesisStreamsEndpointAccessSecurityGroupId: !GetAtt SharedVpcStack.Outputs.KinesisStreamsEndpointAccessSecurityGroupId
StsEndpointAccessSecurityGroupId: !GetAtt SharedVpcStack.Outputs.StsEndpointAccessSecurityGroupId
SharedMemcachedEndpointAddress: !GetAtt SharedMemcachedStack.Outputs.CacheEndpointAddress
SharedRedisClientSecurityGroupId: !GetAtt SharedRedisSecurityGroupStack.Outputs.ClientSecurityGroupId
SharedRedisReplicationGroupEndpointAddress: !GetAtt SharedRedisStack.Outputs.ReplicationGroupEndpointAddress
SharedRedisReplicationGroupEndpointPort: !GetAtt SharedRedisStack.Outputs.ReplicationGroupEndpointPort
AmazonSesSmtpCredentialsGeneratorServiceToken: !GetAtt CustomResourcesStack.Outputs.AmazonSesSmtpCredentialsGeneratorServiceToken
CloudWatchAlarmTaggerServiceToken: !GetAtt CustomResourcesStack.Outputs.CloudWatchAlarmTaggerServiceToken
SharedEcsAsgInstanceSecurityGroupId: !GetAtt SharedEcsAsgSecurityGroupStack.Outputs.InstanceSecurityGroupId
DeploymentPackageBucketName: !GetAtt Constants2.Outputs.DeploymentPackageBucketName
AuguryHostname: !GetAtt Constants2.Outputs.AuguryHostname
BetaHostname: !GetAtt Constants2.Outputs.BetaHostname
CmsHostname: !GetAtt Constants2.Outputs.CmsHostname
ExchangeHostname: !GetAtt Constants2.Outputs.ExchangeHostname
FeederHostname: !GetAtt Constants2.Outputs.FeederHostname
IdHostname: !GetAtt Constants2.Outputs.IdHostname
MetaHostname: !GetAtt Constants2.Outputs.MetaHostname
MetricsHostname: !GetAtt Constants2.Outputs.MetricsHostname
PlayHostname: !GetAtt Constants2.Outputs.PlayHostname
PublishHostname: !GetAtt Constants2.Outputs.PublishHostname
TheWorldSearchHostname: !GetAtt Constants2.Outputs.TheWorldSearchHostname
TheWorldSearchInternalHostname: !GetAtt Constants2.Outputs.TheWorldSearchInternalHostname
SharedAuroraMysqlEndpoint: !Ref SharedAuroraMysqlEndpoint
SharedAuroraMysqlPort: !Ref SharedAuroraMysqlPort
AnnounceResourcePrefix: !GetAtt SharedAnnounceStack.Outputs.ResourcePrefix
PorterJobExecutionSnsTopicArn: !Sub /prx/${EnvironmentTypeAbbreviation}/Spire/${AWS::Region}/porter-job-execution-topic-arn
DovetailCdnLogsKinesisStreamArn: !GetAtt SharedDovetailKinesisStack.Outputs.DovetailCdnLogsKinesisStreamArn
DovetailCountedKinesisStreamArn: !GetAtt SharedDovetailKinesisStack.Outputs.DovetailCountedKinesisStreamArn
# App-specific parameters
CmsSharedAlbListenerRulePriorityPrefix: !FindInMap [SharedAlbListenerRulePriorityMap, Cms, prefix]
IdSharedAlbListenerRulePriorityPrefix: !FindInMap [SharedAlbListenerRulePriorityMap, Id, prefix]
IframelySharedAlbListenerRulePriorityPrefix: !FindInMap [SharedAlbListenerRulePriorityMap, Iframely, prefix]
PlaySharedAlbListenerRulePriorityPrefix: !FindInMap [SharedAlbListenerRulePriorityMap, Play, prefix]
StyleguideSharedAlbListenerRulePriorityPrefix: !FindInMap [SharedAlbListenerRulePriorityMap, Styleguide, prefix]
TheWorldWebsiteSharedAlbListenerRulePriorityPrefix: !FindInMap [SharedAlbListenerRulePriorityMap, TheWorldWebsite, prefix]
Tags:
- { Key: prx:meta:tagging-version, Value: "2021-04-07" }
- { Key: prx:cloudformation:stack-name, Value: !Ref AWS::StackName }
- { Key: prx:cloudformation:stack-id, Value: !Ref AWS::StackId }
- { Key: prx:cloudformation:root-stack-name, Value: !Ref AWS::StackName }
- { Key: prx:cloudformation:root-stack-id, Value: !Ref AWS::StackId }
- { Key: prx:ops:environment, Value: !Ref EnvironmentType }
- { Key: prx:dev:application, Value: Common }
TemplateURL: !Sub ${TemplateUrlBase}/spire/templates/apps-100A.yml
TimeoutInMinutes: 40
Apps200AStack:
Type: AWS::CloudFormation::Stack
Condition: CreateApplicationStacks
DeletionPolicy: Delete
UpdateReplacePolicy: Delete
Properties:
Parameters:
TemplateUrlPrefix: !Sub ${TemplateUrlBase}/spire/templates/apps
SlackMessageRelaySnsTopicArn: !Ref SlackMessageRelayTopicArn
AlbFullName: !GetAtt SharedAlbStack.Outputs.AlbFullName
AlbHttpsListenerArn: !GetAtt SharedAlbStack.Outputs.HttpsListenerArn
EcsClusterArn: !GetAtt SharedEcsClusterStack.Outputs.EcsClusterArn
EcsClusterName: !GetAtt SharedEcsClusterStack.Outputs.EcsClusterName
VpcId: !GetAtt SharedVpcStack.Outputs.VpcId
VpcCidrBlock: !GetAtt SharedVpcStack.Outputs.VpcCidrBlock
VpcIpv6CidrBlocks: !GetAtt SharedVpcStack.Outputs.VpcIpv6CidrBlocks
NewRelicApiKeyPrxLite: !Ref NewRelicApiKeyPrxLite
EnvironmentType: !Ref EnvironmentType
EnvironmentTypeAbbreviation: !Ref EnvironmentTypeAbbreviation
EnvironmentTypeLowercase: !GetAtt Constants2.Outputs.EnvironmentTypeLowercase
RegionMode: !FindInMap [RegionModeMap, !Ref "AWS::Region", !Ref EnvironmentType]
RootStackName: !Ref AWS::StackName
RootStackId: !Ref AWS::StackId
NestedChangeSetScrubbingResourcesState: !Ref NestedChangeSetScrubbingResourcesState
VpcPublicSubnet1Id: !GetAtt SharedVpcStack.Outputs.PublicSubnet1Id
VpcPublicSubnet2Id: !GetAtt SharedVpcStack.Outputs.PublicSubnet2Id
VpcPublicSubnet3Id: !GetAtt SharedVpcStack.Outputs.PublicSubnet3Id
VpcPrivateSubnet1Id: !GetAtt SharedVpcStack.Outputs.PrivateSubnet1Id
VpcPrivateSubnet2Id: !GetAtt SharedVpcStack.Outputs.PrivateSubnet2Id
VpcPrivateSubnet3Id: !GetAtt SharedVpcStack.Outputs.PrivateSubnet3Id
SharedAppRedisEndpointAddress: !GetAtt SharedAppRedisStack.Outputs.CacheEndpointAddress
SharedAppRedisEndpointPort: !GetAtt SharedAppRedisStack.Outputs.CacheEndpointPort
SharedMemcachedEndpointAddress: !GetAtt SharedMemcachedStack.Outputs.CacheEndpointAddress
SharedMemcachedEndpointPort: !GetAtt SharedMemcachedStack.Outputs.CacheEndpointPort
SharedRedisReplicationGroupEndpointAddress: !GetAtt SharedRedisStack.Outputs.ReplicationGroupEndpointAddress
SharedRedisReplicationGroupEndpointPort: !GetAtt SharedRedisStack.Outputs.ReplicationGroupEndpointPort
AmazonSesSmtpCredentialsGeneratorServiceToken: !GetAtt CustomResourcesStack.Outputs.AmazonSesSmtpCredentialsGeneratorServiceToken
EchoServiceToken: !GetAtt CustomResourcesStack.Outputs.EchoServiceToken
CloudWatchAlarmTaggerServiceToken: !GetAtt CustomResourcesStack.Outputs.CloudWatchAlarmTaggerServiceToken
TransferServerIpFinderServiceToken: !GetAtt CustomResourcesStack.Outputs.TransferServerIpFinderServiceToken
EcsLaunchEndpointsAccessSecurityGroupId: !GetAtt SharedVpcStack.Outputs.EcsLaunchEndpointsAccessSecurityGroupId
SystemManagerEndpointAccessSecurityGroupId: !GetAtt SharedVpcStack.Outputs.SystemManagerEndpointAccessSecurityGroupId
KmsEndpointAccessSecurityGroupId: !GetAtt SharedVpcStack.Outputs.KmsEndpointAccessSecurityGroupId
SharedEcsAsgInstanceSecurityGroupId: !GetAtt SharedEcsAsgSecurityGroupStack.Outputs.InstanceSecurityGroupId
SharedMysqlClientSecurityGroupId: !GetAtt SharedDatabaseSecurityGroupsStack.Outputs.SharedMysqlClientSecurityGroupId
S3SigningUserName: !GetAtt Apps100AStack.Outputs.S3SigningUserName
S3SigningEndpointUrl: !GetAtt Apps100AStack.Outputs.S3SigningEndpointUrl
S3SigningAccessKeyId: !GetAtt Apps100AStack.Outputs.S3SigningAccessKeyId
DovetailCdnArrangerFunctionArn: !GetAtt Apps100AStack.Outputs.DovetailCdnArrangerFunctionArn
DovetailCdnArrangerWorkspaceBucketArn: !GetAtt Apps100AStack.Outputs.DovetailCdnArrangerWorkspaceBucketArn
S3StaticSiteDeployServiceToken: !GetAtt CustomResourcesStack.Outputs.S3StaticSiteDeployServiceToken
DeploymentPackageBucketName: !GetAtt Constants2.Outputs.DeploymentPackageBucketName
BetaHostname: !GetAtt Constants2.Outputs.BetaHostname
CastleHostname: !GetAtt Constants2.Outputs.CastleHostname
TheCastleHostname: !GetAtt Constants2.Outputs.TheCastleHostname
CmsHostname: !GetAtt Constants2.Outputs.CmsHostname
TheCountHostname: !GetAtt Constants2.Outputs.TheCountHostname
DovetailRouterHostname: !GetAtt Constants2.Outputs.DovetailRouterHostname
ExchangeHostname: !GetAtt Constants2.Outputs.ExchangeHostname
ExchangeApiHostname: !GetAtt Constants2.Outputs.ExchangeApiHostname
ExchangeTransferHostname: !GetAtt Constants2.Outputs.ExchangeTransferHostname
FeederHostname: !GetAtt Constants2.Outputs.FeederHostname
FeederAssetsHostname: !GetAtt Constants2.Outputs.FeederAssetsHostname
FeederAuthProxyHostname: !GetAtt Constants2.Outputs.FeederAuthProxyHostname
FeederAuthProxyInternalHostname: !GetAtt Constants2.Outputs.FeederAuthProxyInternalHostname
FixerHostname: !GetAtt Constants2.Outputs.FixerHostname
IdHostname: !GetAtt Constants2.Outputs.IdHostname
MetricsHostname: !GetAtt Constants2.Outputs.MetricsHostname
NetworksHostname: !GetAtt Constants2.Outputs.NetworksHostname
PlayHostname: !GetAtt Constants2.Outputs.PlayHostname
FeederCdnHostname: !GetAtt Constants2.Outputs.FeederCdnHostname
PublicFeedsHostname: !GetAtt Constants2.Outputs.PublicFeedsHostname
RemixHostname: !GetAtt Constants2.Outputs.RemixHostname
SharedAuroraMysqlEndpoint: !Ref SharedAuroraMysqlEndpoint
SharedAuroraMysqlPort: !Ref SharedAuroraMysqlPort
SharedAuroraPostgresqlEndpoint: !Ref SharedAuroraPostgresqlEndpoint
SharedAuroraPostgresqlPort: !Ref SharedAuroraPostgresqlPort
AnnounceResourcePrefix: !GetAtt SharedAnnounceStack.Outputs.ResourcePrefix
PorterJobExecutionSnsTopicArn: !Sub /prx/${EnvironmentTypeAbbreviation}/Spire/${AWS::Region}/porter-job-execution-topic-arn
DovetailAppleApiBridgeEndpointUrl: !GetAtt Apps100AStack.Outputs.DovetailAppleApiBridgeEndpointUrl
# App-specific parameters
CastleSharedAlbListenerRulePriorityPrefix: !FindInMap [SharedAlbListenerRulePriorityMap, Castle, prefix]
ExchangeSharedAlbListenerRulePriorityPrefix: !FindInMap [SharedAlbListenerRulePriorityMap, Exchange, prefix]
FeederSharedAlbListenerRulePriorityPrefix: !FindInMap [SharedAlbListenerRulePriorityMap, Feeder, prefix]
NetworksSharedAlbListenerRulePriorityPrefix: !FindInMap [SharedAlbListenerRulePriorityMap, Networks, prefix]
PublishSharedAlbListenerRulePriorityPrefix: !FindInMap [SharedAlbListenerRulePriorityMap, Publish, prefix]
RemixSharedAlbListenerRulePriorityPrefix: !FindInMap [SharedAlbListenerRulePriorityMap, Remix, prefix]
Tags:
- { Key: prx:meta:tagging-version, Value: "2021-04-07" }
- { Key: prx:cloudformation:stack-name, Value: !Ref AWS::StackName }
- { Key: prx:cloudformation:stack-id, Value: !Ref AWS::StackId }
- { Key: prx:cloudformation:root-stack-name, Value: !Ref AWS::StackName }
- { Key: prx:cloudformation:root-stack-id, Value: !Ref AWS::StackId }
- { Key: prx:ops:environment, Value: !Ref EnvironmentType }
- { Key: prx:dev:application, Value: Common }
TemplateURL: !Sub ${TemplateUrlBase}/spire/templates/apps-200A.yml
TimeoutInMinutes: 40
Apps300AStack:
Type: AWS::CloudFormation::Stack
Condition: CreateApplicationStacks
DeletionPolicy: Delete
UpdateReplacePolicy: Delete
Properties:
Parameters:
TemplateUrlPrefix: !Sub ${TemplateUrlBase}/spire/templates/apps
SlackMessageRelaySnsTopicArn: !Ref SlackMessageRelayTopicArn
AlbFullName: !GetAtt SharedAlbStack.Outputs.AlbFullName
AlbHttpsListenerArn: !GetAtt SharedAlbStack.Outputs.HttpsListenerArn
EcsClusterArn: !GetAtt SharedEcsClusterStack.Outputs.EcsClusterArn
EcsClusterName: !GetAtt SharedEcsClusterStack.Outputs.EcsClusterName
VpcId: !GetAtt SharedVpcStack.Outputs.VpcId
NewRelicApiKeyPrxLite: !Ref NewRelicApiKeyPrxLite
EnvironmentType: !Ref EnvironmentType
EnvironmentTypeAbbreviation: !Ref EnvironmentTypeAbbreviation
EnvironmentTypeLowercase: !GetAtt Constants2.Outputs.EnvironmentTypeLowercase
RegionMode: !FindInMap [RegionModeMap, !Ref "AWS::Region", !Ref EnvironmentType]
RootStackName: !Ref AWS::StackName
RootStackId: !Ref AWS::StackId
NestedChangeSetScrubbingResourcesState: !Ref NestedChangeSetScrubbingResourcesState
VpcPublicSubnet1Id: !GetAtt SharedVpcStack.Outputs.PublicSubnet1Id
VpcPublicSubnet2Id: !GetAtt SharedVpcStack.Outputs.PublicSubnet2Id
VpcPublicSubnet3Id: !GetAtt SharedVpcStack.Outputs.PublicSubnet3Id
EcsLaunchEndpointsAccessSecurityGroupId: !GetAtt SharedVpcStack.Outputs.EcsLaunchEndpointsAccessSecurityGroupId
KmsEndpointAccessSecurityGroupId: !GetAtt SharedVpcStack.Outputs.KmsEndpointAccessSecurityGroupId
DeploymentPackageBucketName: !GetAtt Constants2.Outputs.DeploymentPackageBucketName
EchoServiceToken: !GetAtt CustomResourcesStack.Outputs.EchoServiceToken
CloudWatchAlarmTaggerServiceToken: !GetAtt CustomResourcesStack.Outputs.CloudWatchAlarmTaggerServiceToken
SharedEcsAsgInstanceSecurityGroupId: !GetAtt SharedEcsAsgSecurityGroupStack.Outputs.InstanceSecurityGroupId
SharedRedisReplicationGroupEndpointAddress: !GetAtt SharedRedisStack.Outputs.ReplicationGroupEndpointAddress
SharedRedisReplicationGroupEndpointPort: !GetAtt SharedRedisStack.Outputs.ReplicationGroupEndpointPort
SharedAppRedisEndpointAddress: !GetAtt SharedAppRedisStack.Outputs.CacheEndpointAddress
SharedAppRedisEndpointPort: !GetAtt SharedAppRedisStack.Outputs.CacheEndpointPort
SharedAuroraPostgresqlEndpoint: !Ref SharedAuroraPostgresqlEndpoint
SharedAuroraPostgresqlPort: !Ref SharedAuroraPostgresqlPort
SharedPostgresqlClientSecurityGroupId: !GetAtt SharedDatabaseSecurityGroupsStack.Outputs.SharedPostgresqlClientSecurityGroupId
CastlePostgresInstanceEndpointAddress: !GetAtt Apps200AStack.Outputs.CastlePostgresInstanceEndpointAddress
CastlePostgresInstanceEndpointPort: !GetAtt Apps200AStack.Outputs.CastlePostgresInstanceEndpointPort
CastlePostgresClientSecurityGroupId: !GetAtt Apps200AStack.Outputs.CastlePostgresClientSecurityGroupId
CastleHostname: !GetAtt Constants2.Outputs.CastleHostname
TheCountHostname: !GetAtt Constants2.Outputs.TheCountHostname
CorporateHostname: !GetAtt Constants2.Outputs.CorporateHostname
ExchangeHostname: !GetAtt Constants2.Outputs.ExchangeHostname
IdHostname: !GetAtt Constants2.Outputs.IdHostname
AdFilesHostname: !GetAtt Constants2.Outputs.AdFilesHostname
AuguryHostname: !GetAtt Constants2.Outputs.AuguryHostname
FeederHostname: !GetAtt Constants2.Outputs.FeederHostname
MetricsHostname: !GetAtt Constants2.Outputs.MetricsHostname
CmsHostname: !GetAtt Constants2.Outputs.CmsHostname
DovetailCdnHostname: !GetAtt Constants2.Outputs.DovetailCdnHostname
DovetailRouterHostname: !GetAtt Constants2.Outputs.DovetailRouterHostname
SharedGlueDatabaseName: !GetAtt SharedGlueDatabaseStack.Outputs.SharedGlueDatabaseName
DovetailCountedKinesisStreamArn: !GetAtt SharedDovetailKinesisStack.Outputs.DovetailCountedKinesisStreamArn
DovetailCountedKinesisStreamName: !GetAtt SharedDovetailKinesisStack.Outputs.DovetailCountedKinesisStreamName
DovetailVerifiedMetricsKinesisStreamArn: !GetAtt SharedDovetailKinesisStack.Outputs.DovetailVerifiedMetricsKinesisStreamArn
DovetailVerifiedMetricsKinesisStreamName: !GetAtt SharedDovetailKinesisStack.Outputs.DovetailVerifiedMetricsKinesisStreamName
# App-specific parameters
AugurySharedAlbListenerRulePriorityPrefix: !FindInMap [SharedAlbListenerRulePriorityMap, Augury, prefix]
MetricsSharedAlbListenerRulePriorityPrefix: !FindInMap [SharedAlbListenerRulePriorityMap, Metrics, prefix]
Tags:
- { Key: prx:meta:tagging-version, Value: "2021-04-07" }
- { Key: prx:cloudformation:stack-name, Value: !Ref AWS::StackName }
- { Key: prx:cloudformation:stack-id, Value: !Ref AWS::StackId }
- { Key: prx:cloudformation:root-stack-name, Value: !Ref AWS::StackName }
- { Key: prx:cloudformation:root-stack-id, Value: !Ref AWS::StackId }
- { Key: prx:ops:environment, Value: !Ref EnvironmentType }
- { Key: prx:dev:application, Value: Common }
TemplateURL: !Sub ${TemplateUrlBase}/spire/templates/apps-300A.yml
TimeoutInMinutes: 40
Apps400AStack:
Type: AWS::CloudFormation::Stack
Condition: CreateApplicationStacks
DeletionPolicy: Delete
UpdateReplacePolicy: Delete
Properties:
Parameters:
TemplateUrlPrefix: !Sub ${TemplateUrlBase}/spire/templates/apps
EnvironmentType: !Ref EnvironmentType
EnvironmentTypeAbbreviation: !Ref EnvironmentTypeAbbreviation
EnvironmentTypeLowercase: !GetAtt Constants2.Outputs.EnvironmentTypeLowercase
RegionMode: !FindInMap [RegionModeMap, !Ref "AWS::Region", !Ref EnvironmentType]
RootStackName: !Ref AWS::StackName
RootStackId: !Ref AWS::StackId
NestedChangeSetScrubbingResourcesState: !Ref NestedChangeSetScrubbingResourcesState
VpcId: !GetAtt SharedVpcStack.Outputs.VpcId
DeploymentPackageBucketName: !GetAtt Constants2.Outputs.DeploymentPackageBucketName
CloudWatchAlarmTaggerServiceToken: !GetAtt CustomResourcesStack.Outputs.CloudWatchAlarmTaggerServiceToken
TheCountLogsFileSystemId: !GetAtt Apps300AStack.Outputs.TheCountLogsFileSystemId
EcsClusterArn: !GetAtt SharedEcsClusterStack.Outputs.EcsClusterArn
AlbFullName: !GetAtt SharedAlbStack.Outputs.AlbFullName
AlbHttpsListenerArn: !GetAtt SharedAlbStack.Outputs.HttpsListenerArn
AlbInsecureHttpListenerArn: !GetAtt SharedAlbStack.Outputs.InsecureHttpListenerArn
NewRelicApiKeyPrxLite: !Ref NewRelicApiKeyPrxLite
SharedAuroraMysqlEndpoint: !Ref SharedAuroraMysqlEndpoint
SharedAuroraMysqlPort: !Ref SharedAuroraMysqlPort
SharedAuroraPostgresqlEndpoint: !Ref SharedAuroraPostgresqlEndpoint
SharedAuroraPostgresqlPort: !Ref SharedAuroraPostgresqlPort
AnnounceResourcePrefix: !GetAtt SharedAnnounceStack.Outputs.ResourcePrefix
PorterJobExecutionSnsTopicArn: !Sub /prx/${EnvironmentTypeAbbreviation}/Spire/${AWS::Region}/porter-job-execution-topic-arn
ExchangeHostname: !GetAtt Constants2.Outputs.ExchangeHostname
S3SigningEndpointUrl: !GetAtt Apps100AStack.Outputs.S3SigningEndpointUrl
S3SigningAccessKeyId: !GetAtt Apps100AStack.Outputs.S3SigningAccessKeyId
AmazonSesSmtpCredentialsGeneratorServiceToken: !GetAtt CustomResourcesStack.Outputs.AmazonSesSmtpCredentialsGeneratorServiceToken
# App-specific parameters
TheCastleSharedAlbListenerRulePriorityPrefix: !FindInMap [SharedAlbListenerRulePriorityMap, TheCastle, prefix]
WfmtSharedAlbListenerRulePriorityPrefix: !FindInMap [SharedAlbListenerRulePriorityMap, Wfmt, prefix]
WfmtHostname: !GetAtt Constants2.Outputs.WfmtHostname
Tags:
- { Key: prx:meta:tagging-version, Value: "2021-04-07" }
- { Key: prx:cloudformation:stack-name, Value: !Ref AWS::StackName }
- { Key: prx:cloudformation:stack-id, Value: !Ref AWS::StackId }
- { Key: prx:cloudformation:root-stack-name, Value: !Ref AWS::StackName }
- { Key: prx:cloudformation:root-stack-id, Value: !Ref AWS::StackId }
- { Key: prx:ops:environment, Value: !Ref EnvironmentType }
- { Key: prx:dev:application, Value: Common }
TemplateURL: !Sub ${TemplateUrlBase}/spire/templates/apps-400A.yml
TimeoutInMinutes: 40
# Requires VPC, Redis and DB SGs
JumpServerStack:
Type: AWS::CloudFormation::Stack
DeletionPolicy: Delete
UpdateReplacePolicy: Delete
Properties:
Parameters:
AuthorizedKeys: !Join [",", !Ref AuthorizedKeys]
EnvironmentType: !Ref EnvironmentType
RootStackName: !Ref AWS::StackName
RootStackId: !Ref AWS::StackId
NestedChangeSetScrubbingResourcesState: !Ref NestedChangeSetScrubbingResourcesState
CastlePostgresClientSecurityGroupId: !If [CreateApplicationStacks, !GetAtt Apps200AStack.Outputs.CastlePostgresClientSecurityGroupId, ""]
CastlePostgresInstanceEndpointAddress: !If [CreateApplicationStacks, !GetAtt Apps200AStack.Outputs.CastlePostgresInstanceEndpointAddress, ""]
CastlePostgresInstanceEndpointPort: !If [CreateApplicationStacks, !GetAtt Apps200AStack.Outputs.CastlePostgresInstanceEndpointPort, ""]
SharedAuroraMysqlEndpoint: !Ref SharedAuroraMysqlEndpoint
SharedAuroraMysqlPort: !Ref SharedAuroraMysqlPort
SharedAuroraPostgresqlEndpoint: !Ref SharedAuroraPostgresqlEndpoint
SharedAuroraPostgresqlPort: !Ref SharedAuroraPostgresqlPort
SharedEcsClusterName: !GetAtt SharedEcsClusterStack.Outputs.EcsClusterName
SharedMysqlClientSecurityGroupId: !GetAtt SharedDatabaseSecurityGroupsStack.Outputs.SharedMysqlClientSecurityGroupId
SharedPostgresqlClientSecurityGroupId: !GetAtt SharedDatabaseSecurityGroupsStack.Outputs.SharedPostgresqlClientSecurityGroupId
SharedRedisClientSecurityGroupId: !GetAtt SharedRedisSecurityGroupStack.Outputs.ClientSecurityGroupId
SharedRedisReplicationGroupEndpointAddress: !GetAtt SharedRedisStack.Outputs.ReplicationGroupEndpointAddress
SharedRedisReplicationGroupEndpointPort: !GetAtt SharedRedisStack.Outputs.ReplicationGroupEndpointPort
VpcId: !GetAtt SharedVpcStack.Outputs.VpcId
VpcPublicSubnet1Id: !GetAtt SharedVpcStack.Outputs.PublicSubnet1Id
Temp: !Sub /prx/${EnvironmentTypeAbbreviation}/Spire/${AWS::Region}/porter-state-machine-arn
Tags:
- { Key: prx:meta:tagging-version, Value: "2021-04-07" }
- { Key: prx:cloudformation:stack-name, Value: !Ref AWS::StackName }
- { Key: prx:cloudformation:stack-id, Value: !Ref AWS::StackId }
- { Key: prx:cloudformation:root-stack-name, Value: !Ref AWS::StackName }
- { Key: prx:cloudformation:root-stack-id, Value: !Ref AWS::StackId }
- { Key: prx:ops:environment, Value: !Ref EnvironmentType }
- { Key: prx:dev:application, Value: Common }
TemplateURL: !Sub ${TemplateUrlBase}/spire/templates/jump-server.yml
TimeoutInMinutes: 10
# Assumed to require all possible requirements
DashboardsStack:
Type: AWS::CloudFormation::Stack
Condition: CreateDashboardsStack
DeletionPolicy: Delete
UpdateReplacePolicy: Delete
Properties:
Parameters:
EnvironmentType: !Ref EnvironmentType
RootStackName: !Ref AWS::StackName
RootStackId: !Ref AWS::StackName
NestedChangeSetScrubbingResourcesState: !Ref NestedChangeSetScrubbingResourcesState
InfrastructureGitCommit: !Ref InfrastructureGitCommit
SharedEcsClusterName: !GetAtt SharedEcsClusterStack.Outputs.EcsClusterName
SharedVpcId: !GetAtt SharedVpcStack.Outputs.VpcId
SharedVpcCidrBlock: !GetAtt SharedVpcStack.Outputs.VpcCidrBlock
SharedEcsAsgName: !GetAtt SharedEcsAsgStack.Outputs.AsgName
SharedAlbName: !GetAtt SharedAlbStack.Outputs.AlbName
SharedAlbFullName: !GetAtt SharedAlbStack.Outputs.AlbFullName
SharedMemcachedCacheName: !GetAtt SharedMemcachedStack.Outputs.CacheName
SharedAppRedisCacheName: !GetAtt SharedAppRedisStack.Outputs.CacheName
DovetailRedisReplicationGroupName: !GetAtt SharedRedisStack.Outputs.ReplicationGroupName
# TODO
StackResourceGroupName: !If
- IsUsEast1
- !GetAtt ResourceGroupsStack.Outputs.StackResourceGroupName
- TKTKTKTK
StackLogGroupsGroupName: !If
- IsUsEast1
- !GetAtt ResourceGroupsStack.Outputs.StackLogGroupsGroupName
- TKTKTKTK
SharedVpcFlowLogsLogGroupName: !GetAtt SharedVpcStack.Outputs.FlowLogsLogGroupName
AuguryTargetGroupFullName: !GetAtt Apps300AStack.Outputs.AuguryTargetGroupFullName
WfmtTargetGroupFullName: !GetAtt Apps400AStack.Outputs.WfmtTargetGroupFullName
BetaDeployBucketRegionalDomainName: !GetAtt Apps200AStack.Outputs.BetaDeployBucketRegionalDomainName
CastlePostgresInstanceId: !GetAtt Apps200AStack.Outputs.CastlePostgresInstanceId
CastleTargetGroupFullName: !GetAtt Apps200AStack.Outputs.CastleTargetGroupFullName
CmsElasticsearchDomainName: !GetAtt Apps100AStack.Outputs.CmsElasticsearchDomainName
CmsTargetGroupFullName: !GetAtt Apps100AStack.Outputs.CmsTargetGroupFullName
DovetailAppleApiBridgeFunctionId: !GetAtt Apps100AStack.Outputs.DovetailAppleApiBridgeFunctionId
DovetailAlbName: !GetAtt Apps300AStack.Outputs.DovetailAlbName
DovetailAlbFullName: !GetAtt Apps300AStack.Outputs.DovetailAlbFullName
DovetailTargetGroupFullName: !GetAtt Apps300AStack.Outputs.DovetailTargetGroupFullName
ExchangeWebTargetGroupFullName: !GetAtt Apps200AStack.Outputs.ExchangeWebTargetGroupFullName
ExchangeFtpServerId: !GetAtt Apps200AStack.Outputs.ExchangeFtpServerId
ExchangeFtpServerPublicIp: !GetAtt Apps200AStack.Outputs.ExchangeFtpServerPublicIp
ExchangeFtpServerPublicIpAllocationId: !GetAtt Apps200AStack.Outputs.ExchangeFtpServerPublicIpAllocationId
ExchangeFtpServerNlbName: !GetAtt Apps200AStack.Outputs.ExchangeFtpServerNlbName
FeederAuthProxyApiId: !GetAtt Apps200AStack.Outputs.FeederAuthProxyApiId
FeederWebTargetGroupFullName: !GetAtt Apps200AStack.Outputs.FeederWebTargetGroupFullName
IdTargetGroupFullName: !GetAtt Apps100AStack.Outputs.IdTargetGroupFullName
IframelyTargetGroupFullName: !GetAtt Apps100AStack.Outputs.IframelyTargetGroupFullName
MetricsTargetGroupFullName: !GetAtt Apps300AStack.Outputs.MetricsTargetGroupFullName
NetworksPublicWebTargetGroupFullName: !GetAtt Apps200AStack.Outputs.NetworksPublicWebTargetGroupFullName
PlayWebTargetGroupFullName: !GetAtt Apps100AStack.Outputs.PlayWebTargetGroupFullName
ProxyApiDefaultEndpoint: !GetAtt Apps300AStack.Outputs.ProxyApiDefaultEndpoint
ProxyApiId: !GetAtt Apps300AStack.Outputs.ProxyApiId
PublishTargetGroupFullName: !GetAtt Apps200AStack.Outputs.PublishTargetGroupFullName