Skip to content
This repository was archived by the owner on Oct 4, 2024. It is now read-only.

Commit 5cd3408

Browse files
Change Join functions to Sub functions. Update shorthands everywhere except for Sub.
1 parent 70923d5 commit 5cd3408

File tree

1 file changed

+29
-80
lines changed

1 file changed

+29
-80
lines changed

templates/marketplace/master-mp.template

Lines changed: 29 additions & 80 deletions
Original file line numberDiff line numberDiff line change
@@ -362,7 +362,7 @@ Resources:
362362
Condition: LaunchRDSInstance
363363
Properties:
364364
TemplateURL:
365-
!Sub
365+
Fn::Sub:
366366
- https://${QSS3BucketName}.${QSS3Region}.amazonaws.com/${QSS3KeyPrefix}templates/marketplace/dsm-mp.template
367367
- QSS3Region:
368368
!If
@@ -377,9 +377,7 @@ Resources:
377377
DSCAdminName: !Ref DSCAdminName
378378
DSCAdminPassword: !Ref DSCAdminPassword
379379
DBPRDSEndpoint:
380-
!GetAtt
381-
- DSDatabaseAbstract
382-
- Outputs.DSDBEndpoint
380+
!GetAtt DSDatabaseAbstract.Outputs.DSDBEndpoint
383381
DBPName: !Ref DBPName
384382
DBICAdminName: !Ref DBICAdminName
385383
DBICAdminPassword: !Ref DBICAdminPassword
@@ -388,21 +386,15 @@ Resources:
388386
DSMPMNode: 'No'
389387
DSISubnetID: !Ref DSISubnetID
390388
DSMSG:
391-
!GetAtt
392-
- DSIDSMSecurityGroup
393-
- Outputs.DSMSG
389+
!GetAtt DSIDSMSecurityGroup.Outputs.DSMSG
394390
DBPEngine: !Ref DBPEngine
395391
DSIPInstanceType: !Ref DSIPInstanceType
396392
CreateEIP: 'False'
397393
DSIELB:
398-
!GetAtt
399-
- DSIELB
400-
- Outputs.DSIELB
394+
!GetAtt DSIELB.Outputs.DSIELB
401395
DSM1CompleteWaitHandle: !Ref DSM1CompleteWaitHandle
402396
DSIELBFQDN:
403-
!GetAtt
404-
- DSIELB
405-
- Outputs.ELBFQDN
397+
!GetAtt DSIELB.Outputs.ELBFQDN
406398
DSELBPosture: !Ref DSELBPosture
407399
QSS3BucketName: !Ref QSS3BucketName
408400
QSS3KeyPrefix: !Ref QSS3KeyPrefix
@@ -416,7 +408,7 @@ Resources:
416408
Condition: DSMNode2DB
417409
Properties:
418410
TemplateURL:
419-
!Sub
411+
Fn::Sub:
420412
- https://${QSS3BucketName}.${QSS3Region}.amazonaws.com/${QSS3KeyPrefix}templates/marketplace/dsm-mp.template
421413
- QSS3Region:
422414
!If
@@ -431,9 +423,7 @@ Resources:
431423
DSCAdminName: !Ref DSCAdminName
432424
DSCAdminPassword: !Ref DSCAdminPassword
433425
DBPRDSEndpoint:
434-
!GetAtt
435-
- DSDatabaseAbstract
436-
- Outputs.DSDBEndpoint
426+
!GetAtt DSDatabaseAbstract.Outputs.DSDBEndpoint
437427
DBPName: !Ref DBPName
438428
DBICAdminName: !Ref DBICAdminName
439429
DBICAdminPassword: !Ref DBICAdminPassword
@@ -442,16 +432,12 @@ Resources:
442432
DSMPMNode: 'Yes'
443433
DSISubnetID: !Ref DSISubnetID
444434
DSMSG:
445-
!GetAtt
446-
- DSIDSMSecurityGroup
447-
- Outputs.DSMSG
435+
!GetAtt DSIDSMSecurityGroup.Outputs.DSMSG
448436
DBPEngine: !Ref DBPEngine
449437
DSIPInstanceType: !Ref DSIPInstanceType
450438
CreateEIP: 'False'
451439
DSIELB:
452-
!GetAtt
453-
- DSIELB
454-
- Outputs.DSIELB
440+
!GetAtt DSIELB.Outputs.DSIELB
455441
DSELBPosture: !Ref DSELBPosture
456442
QSS3BucketName: !Ref QSS3BucketName
457443
QSS3KeyPrefix: !Ref QSS3KeyPrefix
@@ -463,7 +449,7 @@ Resources:
463449
Condition: DoNotLaunchRDSInstance
464450
Properties:
465451
TemplateURL:
466-
!Sub
452+
Fn::Sub:
467453
- https://${QSS3BucketName}.${QSS3Region}.amazonaws.com/${QSS3KeyPrefix}templates/marketplace/dsm-mp.template
468454
- QSS3Region:
469455
!If
@@ -486,21 +472,15 @@ Resources:
486472
DSMPMNode: 'No'
487473
DSISubnetID: !Ref DSISubnetID
488474
DSMSG:
489-
!GetAtt
490-
- DSIDSMSecurityGroup
491-
- Outputs.DSMSG
475+
!GetAtt DSIDSMSecurityGroup.Outputs.DSMSG
492476
DBPEngine: !Ref DBPEngine
493477
DSIPInstanceType: !Ref DSIPInstanceType
494478
CreateEIP: 'False'
495479
DSM1NoDBCompleteWaitHandle: !Ref DSM1NoDBCompleteWaitHandle
496480
DSIELB:
497-
!GetAtt
498-
- DSIELB
499-
- Outputs.DSIELB
481+
!GetAtt DSIELB.Outputs.DSIELB
500482
DSIELBFQDN:
501-
!GetAtt
502-
- DSIELB
503-
- Outputs.ELBFQDN
483+
!GetAtt DSIELB.Outputs.ELBFQDN
504484
DSELBPosture: !Ref DSELBPosture
505485
QSS3BucketName: !Ref QSS3BucketName
506486
QSS3KeyPrefix: !Ref QSS3KeyPrefix
@@ -511,7 +491,7 @@ Resources:
511491
Condition: DSMNode2NoDB
512492
Properties:
513493
TemplateURL:
514-
!Sub
494+
Fn::Sub:
515495
- https://${QSS3BucketName}.${QSS3Region}.amazonaws.com/${QSS3KeyPrefix}templates/marketplace/dsm-mp.template
516496
- QSS3Region:
517497
!If
@@ -534,16 +514,12 @@ Resources:
534514
DSMPMNode: 'Yes'
535515
DSISubnetID: !Ref DSISubnetID
536516
DSMSG:
537-
!GetAtt
538-
- DSIDSMSecurityGroup
539-
- Outputs.DSMSG
517+
!GetAtt DSIDSMSecurityGroup.Outputs.DSMSG
540518
DBPEngine: !Ref DBPEngine
541519
DSIPInstanceType: !Ref DSIPInstanceType
542520
CreateEIP: 'False'
543521
DSIELB:
544-
!GetAtt
545-
- DSIELB
546-
- Outputs.DSIELB
522+
!GetAtt DSIELB.Outputs.DSIELB
547523
DSELBPosture: !Ref DSELBPosture
548524
QSS3BucketName: !Ref QSS3BucketName
549525
QSS3KeyPrefix: !Ref QSS3KeyPrefix
@@ -554,7 +530,7 @@ Resources:
554530
DependsOn: DSIRDSSecurityGroup
555531
Properties:
556532
TemplateURL:
557-
!Sub
533+
Fn::Sub:
558534
- https://${QSS3BucketName}.${QSS3Region}.amazonaws.com/${QSS3KeyPrefix}templates/common/db/ds-db-abstract.template
559535
- QSS3Region:
560536
!If
@@ -569,9 +545,7 @@ Resources:
569545
DBICAdminName: !Ref DBICAdminName
570546
DBICAdminPassword: !Ref DBICAdminPassword
571547
RDSSG:
572-
!GetAtt
573-
- DSIRDSSecurityGroup
574-
- Outputs.RDSSG
548+
!GetAtt DSIRDSSecurityGroup.Outputs.RDSSG
575549
MultiAZ: !Ref DBPMultiAZ
576550
StorageType: gp2
577551
DBPBackupDays: !Ref DBPBackupDays
@@ -584,7 +558,7 @@ Resources:
584558
Condition: LaunchRDSInstance
585559
Properties:
586560
TemplateURL:
587-
!Sub
561+
Fn::Sub:
588562
- https://${QSS3BucketName}.${QSS3Region}.amazonaws.com/${QSS3KeyPrefix}templates/common/security-groups/rds-security-group.template
589563
- QSS3Region:
590564
!If
@@ -595,14 +569,12 @@ Resources:
595569
AWSIVPC: !Ref AWSIVPC
596570
DBPEngine: !Ref DBPEngine
597571
DSMSG:
598-
!GetAtt
599-
- DSIDSMSecurityGroup
600-
- Outputs.DSMSG
572+
!GetAtt DSIDSMSecurityGroup.Outputs.DSMSG
601573
DSIDSMSecurityGroup:
602574
Type: AWS::CloudFormation::Stack
603575
Properties:
604576
TemplateURL:
605-
!Sub
577+
Fn::Sub:
606578
- https://${QSS3BucketName}.${QSS3Region}.amazonaws.com/${QSS3KeyPrefix}templates/common/security-groups/dsm-security-group.template
607579
- QSS3Region:
608580
!If
@@ -617,7 +589,7 @@ Resources:
617589
Type: AWS::CloudFormation::Stack
618590
Properties:
619591
TemplateURL:
620-
!Sub
592+
Fn::Sub:
621593
- https://${QSS3BucketName}.${QSS3Region}.amazonaws.com/${QSS3KeyPrefix}templates/common/dsm-elb.template
622594
- QSS3Region:
623595
!If
@@ -636,7 +608,7 @@ Resources:
636608
Type: AWS::CloudFormation::Stack
637609
Properties:
638610
TemplateURL:
639-
!Sub
611+
Fn::Sub:
640612
- https://${QSS3BucketName}.${QSS3Region}.amazonaws.com/${QSS3KeyPrefix}templates/common/security-groups/dsm-sg-ingress-rules.template
641613
- QSS3Region:
642614
!If
@@ -645,13 +617,9 @@ Resources:
645617
- s3
646618
Parameters:
647619
DSMSG:
648-
!GetAtt
649-
- DSIDSMSecurityGroup
650-
- Outputs.DSMSG
620+
!GetAtt DSIDSMSecurityGroup.Outputs.DSMSG
651621
ELBSourceSG:
652-
!GetAtt
653-
- DSIELB
654-
- Outputs.ELBSourceSecurityGroup
622+
!GetAtt DSIELB.Outputs.ELBSourceSecurityGroup
655623
DSIPHeartbeatPort: !Ref DSIPHeartbeatPort
656624
DSIPGUIPort: !Ref DSIPGUIPort
657625
DSM1CompleteWaitHandle:
@@ -708,33 +676,14 @@ Conditions:
708676
Outputs:
709677
DeepSecurityConsole:
710678
Value:
711-
!Join
712-
- ''
713-
- - https://
714-
- !GetAtt
715-
- DSIELB
716-
- Outputs.ELBFQDN
717-
- ':'
718-
- !Ref DSIPGUIPort
679+
Fn::Sub: https://${DSIELB.Outputs.ELBFQDN}:${DSIPGUIPort}
719680
DeepSecurityHeartbeat:
720681
Value:
721-
!Join
722-
- ''
723-
- - dsm://
724-
- !GetAtt
725-
- DSIELB
726-
- Outputs.ELBFQDN
727-
- ':'
728-
- !Ref DSIPHeartbeatPort
729-
- /
682+
Fn::Sub: dsm://${DSIELB.Outputs.ELBFQDN}:${DSIPHeartbeatPort}/
730683
ELBCanonicalHostedZoneNameID:
731684
Value:
732-
!GetAtt
733-
- DSIELB
734-
- Outputs.ELBCanonicalHostedZoneNameID
685+
!GetAtt DSIELB.Outputs.ELBCanonicalHostedZoneNameID
735686
ELBDNSName:
736687
Value:
737-
!GetAtt
738-
- DSIELB
739-
- Outputs.ELBDNSName
688+
!GetAtt DSIELB.Outputs.ELBDNSName
740689
...

0 commit comments

Comments
 (0)