|
670 | 670 | ],
|
671 | 671 | "UpdateReplacePolicy": "Delete",
|
672 | 672 | "DeletionPolicy": "Delete"
|
| 673 | + }, |
| 674 | + "DatabaseClusterPostgresqlSubnetsE0173DAA": { |
| 675 | + "Type": "AWS::RDS::DBSubnetGroup", |
| 676 | + "Properties": { |
| 677 | + "DBSubnetGroupDescription": "Subnets for DatabaseClusterPostgresql database", |
| 678 | + "SubnetIds": [ |
| 679 | + { |
| 680 | + "Ref": "VPCPrivateSubnet1Subnet8BCA10E0" |
| 681 | + }, |
| 682 | + { |
| 683 | + "Ref": "VPCPrivateSubnet2SubnetCFCDAA7A" |
| 684 | + } |
| 685 | + ] |
| 686 | + } |
| 687 | + }, |
| 688 | + "DatabaseClusterPostgresqlSecurityGroupEF4103D2": { |
| 689 | + "Type": "AWS::EC2::SecurityGroup", |
| 690 | + "Properties": { |
| 691 | + "GroupDescription": "RDS security group", |
| 692 | + "SecurityGroupEgress": [ |
| 693 | + { |
| 694 | + "CidrIp": "0.0.0.0/0", |
| 695 | + "Description": "Allow all outbound traffic by default", |
| 696 | + "IpProtocol": "-1" |
| 697 | + } |
| 698 | + ], |
| 699 | + "VpcId": { |
| 700 | + "Ref": "VPCB9E5F0B4" |
| 701 | + } |
| 702 | + } |
| 703 | + }, |
| 704 | + "DatabaseClusterPostgresqlSecretD2D9C157": { |
| 705 | + "Type": "AWS::SecretsManager::Secret", |
| 706 | + "Properties": { |
| 707 | + "Description": { |
| 708 | + "Fn::Join": [ |
| 709 | + "", |
| 710 | + [ |
| 711 | + "Generated by the CDK for stack: ", |
| 712 | + { |
| 713 | + "Ref": "AWS::StackName" |
| 714 | + } |
| 715 | + ] |
| 716 | + ] |
| 717 | + }, |
| 718 | + "GenerateSecretString": { |
| 719 | + "ExcludeCharacters": " %+~`#$&*()|[]{}:;<>?!'/@\"\\", |
| 720 | + "GenerateStringKey": "password", |
| 721 | + "PasswordLength": 30, |
| 722 | + "SecretStringTemplate": "{\"username\":\"postgres\"}" |
| 723 | + } |
| 724 | + }, |
| 725 | + "UpdateReplacePolicy": "Delete", |
| 726 | + "DeletionPolicy": "Delete" |
| 727 | + }, |
| 728 | + "DatabaseClusterPostgresqlSecretAttachment09D32DC9": { |
| 729 | + "Type": "AWS::SecretsManager::SecretTargetAttachment", |
| 730 | + "Properties": { |
| 731 | + "SecretId": { |
| 732 | + "Ref": "DatabaseClusterPostgresqlSecretD2D9C157" |
| 733 | + }, |
| 734 | + "TargetId": { |
| 735 | + "Ref": "DatabaseClusterPostgresql0775776E" |
| 736 | + }, |
| 737 | + "TargetType": "AWS::RDS::DBCluster" |
| 738 | + } |
| 739 | + }, |
| 740 | + "DatabaseClusterPostgresql0775776E": { |
| 741 | + "Type": "AWS::RDS::DBCluster", |
| 742 | + "Properties": { |
| 743 | + "CopyTagsToSnapshot": true, |
| 744 | + "DBClusterParameterGroupName": "default.aurora-postgresql16", |
| 745 | + "DBSubnetGroupName": { |
| 746 | + "Ref": "DatabaseClusterPostgresqlSubnetsE0173DAA" |
| 747 | + }, |
| 748 | + "EnableLocalWriteForwarding": true, |
| 749 | + "Engine": "aurora-postgresql", |
| 750 | + "EngineVersion": "16.4", |
| 751 | + "MasterUserPassword": { |
| 752 | + "Fn::Join": [ |
| 753 | + "", |
| 754 | + [ |
| 755 | + "{{resolve:secretsmanager:", |
| 756 | + { |
| 757 | + "Ref": "DatabaseClusterPostgresqlSecretD2D9C157" |
| 758 | + }, |
| 759 | + ":SecretString:password::}}" |
| 760 | + ] |
| 761 | + ] |
| 762 | + }, |
| 763 | + "MasterUsername": { |
| 764 | + "Fn::Join": [ |
| 765 | + "", |
| 766 | + [ |
| 767 | + "{{resolve:secretsmanager:", |
| 768 | + { |
| 769 | + "Ref": "DatabaseClusterPostgresqlSecretD2D9C157" |
| 770 | + }, |
| 771 | + ":SecretString:username::}}" |
| 772 | + ] |
| 773 | + ] |
| 774 | + }, |
| 775 | + "Port": 5432, |
| 776 | + "ServerlessV2ScalingConfiguration": { |
| 777 | + "MaxCapacity": 2, |
| 778 | + "MinCapacity": 0.5 |
| 779 | + }, |
| 780 | + "VpcSecurityGroupIds": [ |
| 781 | + { |
| 782 | + "Fn::GetAtt": [ |
| 783 | + "DatabaseClusterPostgresqlSecurityGroupEF4103D2", |
| 784 | + "GroupId" |
| 785 | + ] |
| 786 | + } |
| 787 | + ] |
| 788 | + }, |
| 789 | + "UpdateReplacePolicy": "Snapshot", |
| 790 | + "DeletionPolicy": "Snapshot" |
| 791 | + }, |
| 792 | + "DatabaseClusterPostgresqlwriterInstanceB16652DD": { |
| 793 | + "Type": "AWS::RDS::DBInstance", |
| 794 | + "Properties": { |
| 795 | + "DBClusterIdentifier": { |
| 796 | + "Ref": "DatabaseClusterPostgresql0775776E" |
| 797 | + }, |
| 798 | + "DBInstanceClass": "db.serverless", |
| 799 | + "Engine": "aurora-postgresql", |
| 800 | + "PromotionTier": 0 |
| 801 | + }, |
| 802 | + "DependsOn": [ |
| 803 | + "VPCPrivateSubnet1DefaultRouteAE1D6490", |
| 804 | + "VPCPrivateSubnet1RouteTableAssociation347902D1", |
| 805 | + "VPCPrivateSubnet2DefaultRouteF4F5CFD2", |
| 806 | + "VPCPrivateSubnet2RouteTableAssociation0C73D413" |
| 807 | + ], |
| 808 | + "UpdateReplacePolicy": "Delete", |
| 809 | + "DeletionPolicy": "Delete" |
| 810 | + }, |
| 811 | + "DatabaseClusterPostgresqlreaderInstance10798C6B0": { |
| 812 | + "Type": "AWS::RDS::DBInstance", |
| 813 | + "Properties": { |
| 814 | + "DBClusterIdentifier": { |
| 815 | + "Ref": "DatabaseClusterPostgresql0775776E" |
| 816 | + }, |
| 817 | + "DBInstanceClass": "db.serverless", |
| 818 | + "Engine": "aurora-postgresql", |
| 819 | + "PromotionTier": 2 |
| 820 | + }, |
| 821 | + "DependsOn": [ |
| 822 | + "DatabaseClusterPostgresqlwriterInstanceB16652DD", |
| 823 | + "VPCPrivateSubnet1DefaultRouteAE1D6490", |
| 824 | + "VPCPrivateSubnet1RouteTableAssociation347902D1", |
| 825 | + "VPCPrivateSubnet2DefaultRouteF4F5CFD2", |
| 826 | + "VPCPrivateSubnet2RouteTableAssociation0C73D413" |
| 827 | + ], |
| 828 | + "UpdateReplacePolicy": "Delete", |
| 829 | + "DeletionPolicy": "Delete" |
673 | 830 | }
|
674 | 831 | },
|
675 | 832 | "Mappings": {
|
|
0 commit comments