--- AWSTemplateFormatVersion: 2010-09-09 Description: "Deploys a three-tier Progress OpenEdge stack into a new VPC (qs-1qtcokh3l)" Metadata: cfn-lint: config: ignore_checks: - W9006 QuickStartDocumentation: EntrypointName: "Launch into a new VPC" LICENSE: Apache License Version 2.0 AWS::CloudFormation::Interface: ParameterGroups: - Label: default: VPC parameters Parameters: - AvailabilityZones - Label: default: OpenEdge parameters Parameters: - RemoteAccessCIDR - WebAccessCIDR - EmailAddress - DeployBucket - DeployBucketRegion - DBDeployPackage - PASOEDeployPackage - WebDeployPackage - Label: default: OpenEdge database configuration Parameters: - PortNumber - MinPort - MaxPort - Label: default: Network configuration Parameters: - PrivateSubnet1CIDR - PrivateSubnet2CIDR - PublicSubnet1CIDR - PublicSubnet2CIDR - VPCCIDR - Label: default: Amazon EC2 configuration Parameters: - KeyPairName - BastionAMIOS - BastionInstanceType - InstanceType - MinScalingInstances - MaxScalingInstances - Label: default: AWS Quick Start configuration Parameters: - QSS3BucketName - QSS3BucketRegion - QSS3KeyPrefix ParameterLabels: AvailabilityZones: default: Availability Zones DeployBucket: default: S3 bucket with deployment assets DeployBucketRegion: default: Region in which the deployment assets are stored KeyPairName: default: EC2 key pair RemoteAccessCIDR: default: Remote access CIDR WebAccessCIDR: default: Web access CIDR EmailAddress: default: Email address DBDeployPackage: default: Database deploy package PASOEDeployPackage: default: PASOE deploy package WebDeployPackage: default: Web deploy package PortNumber: default: Port number MinPort: default: Min port MaxPort: default: Max port PrivateSubnet1CIDR: default: Private subnet 1 CIDR PrivateSubnet2CIDR: default: Private subnet 2 CIDR PublicSubnet1CIDR: default: Public subnet 1 CIDR PublicSubnet2CIDR: default: Public subnet 2 CIDR VPCCIDR: default: VPC CIDR BastionAMIOS: default: Bastion AMI OS BastionInstanceType: default: Bastion instance type InstanceType: default: Instance type MinScalingInstances: default: Minimum instances in ASG MaxScalingInstances: default: Maximum instances in ASG QSS3BucketName: default: Quick Start S3 bucket QSS3BucketRegion: default: Quick Start S3 bucket Region QSS3KeyPrefix: default: Quick Start S3 key prefix Parameters: DeployBucket: Description: S3 bucket containing deployment packages. Type: String MinLength: 1 DeployBucketRegion: Description: Region in which the deployment packages are stored. Type: String MinLength: 1 Default: us-east-1 DBDeployPackage: Description: S3 key for package to deploy databases into EC2 instances. Type: String MinLength: 1 Default: db.tar.gz PASOEDeployPackage: Description: S3 key for package to deploy databases into PASOE EC2 instances. Type: String MinLength: 1 Default: pas.tar.gz WebDeployPackage: Description: S3 key for package to deploy web UI into WebServer EC2 instances. Type: String MinLength: 1 Default: web.tar.gz PortNumber: Description: Port number to connect to the database broker process. Type: Number Default: 20000 MinPort: Description: Use the minimum dynamic server (-minport) number within a specified range of port numbers that are accessible to a client. Type: Number Default: 1025 MaxPort: Description: Use the maximum dynamic server (-minport) number within a specified range of port numbers that are accessible to a client. Type: Number Default: 2000 EmailAddress: AllowedPattern: "([a-zA-Z0-9_\\-\\.]+)@((\\[[0-9]{1,3}\\.[0-9]{1,3}\\.[0-9]{1,3}\\.)|(([a-zA-Z0-9\\-]+\\.)+))([a-zA-Z]{2,4}|[0-9]{1,3})(\\]?)" ConstraintDescription: "Must be a valid email ID." Description: "Email address for notification." Type: String AvailabilityZones: Description: List of Availability Zones to use for the subnets in the VPC. Only two Availability Zones are used for this deployment. Type: List InstanceType: Description: "EC2 instance type" Type: String Default: t3.large AllowedValues: - t3.large - t3.xlarge - t3.2xlarge - t3a.large - t3a.xlarge - t3a.2xlarge - m6i.large - m6i.xlarge - m6i.2xlarge - m6i.4xlarge - m6i.8xlarge - m6i.12xlarge - m6i.16xlarge - m6i.24xlarge - m6i.32xlarge - m6id.large - m6id.xlarge - m6id.2xlarge - m6id.4xlarge - m6id.8xlarge - m6id.12xlarge - m6id.16xlarge - m6id.24xlarge - m6id.32xlarge - m6in.large - m6in.xlarge - m6in.2xlarge - m6in.4xlarge - m6in.8xlarge - m6in.12xlarge - m6in.16xlarge - m6in.24xlarge - m6in.32xlarge - m6idn.large - m6idn.xlarge - m6idn.2xlarge - m6idn.4xlarge - m6idn.8xlarge - m6idn.12xlarge - m6idn.16xlarge - m6idn.24xlarge - m6idn.32xlarge - m6a.large - m6a.xlarge - m6a.2xlarge - m6a.4xlarge - m6a.8xlarge - m6a.12xlarge - m6a.16xlarge - m6a.24xlarge - m6a.32xlarge - m6a.48xlarge - c6i.xlarge - c6i.2xlarge - c6i.4xlarge - c6i.8xlarge - c6i.12xlarge - c6i.16xlarge - c6i.24xlarge - c6i.32xlarge - c6id.xlarge - c6id.2xlarge - c6id.4xlarge - c6id.8xlarge - c6id.12xlarge - c6id.16xlarge - c6id.24xlarge - c6id.32xlarge - c6in.xlarge - c6in.2xlarge - c6in.4xlarge - c6in.8xlarge - c6in.12xlarge - c6in.16xlarge - c6in.24xlarge - c6in.32xlarge - c6a.xlarge - c6a.2xlarge - c6a.4xlarge - c6a.8xlarge - c6a.12xlarge - c6a.16xlarge - c6a.24xlarge - c6a.32xlarge - c6a.48xlarge - r6i.large - r6i.xlarge - r6i.2xlarge - r6i.4xlarge - r6i.8xlarge - r6i.12xlarge - r6i.16xlarge - r6i.24xlarge - r6i.32xlarge - r6id.large - r6id.xlarge - r6id.2xlarge - r6id.4xlarge - r6id.8xlarge - r6id.12xlarge - r6id.16xlarge - r6id.24xlarge - r6id.32xlarge - r6in.large - r6in.xlarge - r6in.2xlarge - r6in.4xlarge - r6in.8xlarge - r6in.12xlarge - r6in.16xlarge - r6in.24xlarge - r6in.32xlarge - r6idn.large - r6idn.xlarge - r6idn.2xlarge - r6idn.4xlarge - r6idn.8xlarge - r6idn.12xlarge - r6idn.16xlarge - r6idn.24xlarge - r6idn.32xlarge - r6a.large - r6a.xlarge - r6a.2xlarge - r6a.4xlarge - r6a.8xlarge - r6a.12xlarge - r6a.16xlarge - r6a.24xlarge - r6a.32xlarge - r6a.48xlarge ConstraintDescription: "Must be a valid EC2 instance type." BastionAMIOS: AllowedValues: - Amazon-Linux2-HVM - CentOS-7-HVM - Ubuntu-Server-20.04-LTS-HVM - SUSE-SLES-15-HVM Default: Amazon-Linux2-HVM Description: Linux distribution for the AMI to be used for the bastion instances. Type: String BastionInstanceType: AllowedValues: - t3.nano - t3.micro - t3.small - t3.medium - t3.large - t3.xlarge - t3.2xlarge - m6i.large - m6i.xlarge - m6i.2xlarge - m6i.4xlarge - m6a.large - m6a.xlarge - m6a.2xlarge - m6a.4xlarge Default: t3.micro Description: Amazon EC2 instance type for the bastion instances. Type: String KeyPairName: ConstraintDescription: "Name of an existing EC2 key pair." Description: EC2 key pair Type: "AWS::EC2::KeyPair::KeyName" PrivateSubnet1CIDR: AllowedPattern: ^(([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\.){3}([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])(\/(1[6-9]|2[0-8]))$ ConstraintDescription: CIDR block parameter must be in the form x.x.x.x/16-28. Default: 10.0.0.0/19 Description: CIDR block for private subnet 1, located in Availability Zone 1. Type: String PrivateSubnet2CIDR: AllowedPattern: ^(([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\.){3}([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])(\/(1[6-9]|2[0-8]))$ ConstraintDescription: CIDR block parameter must be in the form x.x.x.x/16-28. Default: 10.0.32.0/19 Description: CIDR block for private subnet 2, located in Availability Zone 2. Type: String PublicSubnet1CIDR: AllowedPattern: ^(([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\.){3}([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])(\/(1[6-9]|2[0-8]))$ ConstraintDescription: CIDR block parameter must be in the form x.x.x.x/16-28. Default: 10.0.128.0/20 Description: CIDR block for the public (DMZ) subnet 1, located in Availability Zone 1. Type: String PublicSubnet2CIDR: AllowedPattern: ^(([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\.){3}([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])(\/(1[6-9]|2[0-8]))$ ConstraintDescription: CIDR block parameter must be in the form x.x.x.x/16-28. Default: 10.0.144.0/20 Description: CIDR block for the public (DMZ) subnet 2, located in Availability Zone 2. Type: String VPCCIDR: AllowedPattern: ^(([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\.){3}([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])(\/(1[6-9]|2[0-8]))$ ConstraintDescription: CIDR block parameter must be in the form x.x.x.x/16-28. Default: 10.0.0.0/16 Description: CIDR block for the VPC. Type: String QSS3BucketName: AllowedPattern: "^[0-9a-zA-Z]+([0-9a-zA-Z-]*[0-9a-zA-Z])*$" ConstraintDescription: "Quick Start bucket name can include numbers, lowercase letters, uppercase letters, and hyphens (-). It cannot start or end with a hyphen (-)." Default: aws-quickstart Description: "S3 bucket name for the Quick Start assets. Quick Start bucket name can include numbers, lowercase letters, uppercase letters, and hyphens (-). It cannot start or end with a hyphen (-)." Type: String QSS3BucketRegion: Default: 'us-east-1' Description: "AWS Region where the Quick Start S3 bucket (QSS3BucketName) is hosted. If you use your own bucket, specify that value." Type: String QSS3KeyPrefix: AllowedPattern: "^[0-9a-zA-Z-/]*$" ConstraintDescription: "Quick Start key prefix can include numbers, lowercase letters, uppercase letters, hyphens (-), and forward slash (/)." Default: quickstart-progress-openedge/ Description: "S3 key prefix for the Quick Start assets. Quick Start key prefix can include numbers, lowercase letters, uppercase letters, hyphens (-), and forward slash (/)." Type: String RemoteAccessCIDR: AllowedPattern: "^(([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\\.){3}([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])(\\/([0-9]|[1-2][0-9]|3[0-2]))$" ConstraintDescription: "CIDR block parameter must be in the form x.x.x.x/x." Description: "Allowed CIDR block for external SSH access" Type: String WebAccessCIDR: AllowedPattern: "^(([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\\.){3}([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])(\\/([0-9]|[1-2][0-9]|3[0-2]))$" ConstraintDescription: "CIDR block parameter must be in the form x.x.x.x/x." Description: "Allowed CIDR block for web access" Type: String MinScalingInstances: Default: '2' Description: Minimum number of EC2 instances in the Auto Scaling group. Type: String MaxScalingInstances: Default: '8' Description: Maximum number of EC2 instances in the Auto Scaling group. Type: String Conditions: UsingDefaultBucket: !Equals [!Ref QSS3BucketName, 'aws-quickstart'] Resources: VPCStack: Type: "AWS::CloudFormation::Stack" Properties: TemplateURL: !Sub - https://${S3Bucket}.s3.${S3Region}.${AWS::URLSuffix}/${QSS3KeyPrefix}submodules/quickstart-aws-vpc/templates/aws-vpc.template.yaml - S3Region: !If [UsingDefaultBucket, !Ref 'AWS::Region', !Ref QSS3BucketRegion] S3Bucket: !If [UsingDefaultBucket, !Sub '${QSS3BucketName}-${AWS::Region}', !Ref QSS3BucketName] Parameters: AvailabilityZones: !Join - "," - !Ref AvailabilityZones NumberOfAZs: "2" PrivateSubnet1ACIDR: !Ref PrivateSubnet1CIDR PrivateSubnet2ACIDR: !Ref PrivateSubnet2CIDR PublicSubnet1CIDR: !Ref PublicSubnet1CIDR PublicSubnet2CIDR: !Ref PublicSubnet2CIDR VPCCIDR: !Ref VPCCIDR BastionStack: Type: AWS::CloudFormation::Stack Properties: TemplateURL: !Sub - https://${S3Bucket}.s3.${S3Region}.${AWS::URLSuffix}/${QSS3KeyPrefix}submodules/quickstart-linux-bastion/templates/linux-bastion.template - S3Region: !If [UsingDefaultBucket, !Ref 'AWS::Region', !Ref QSS3BucketRegion] S3Bucket: !If [UsingDefaultBucket, !Sub '${QSS3BucketName}-${AWS::Region}', !Ref QSS3BucketName] Parameters: BastionAMIOS: Ref: BastionAMIOS BastionInstanceType: Ref: BastionInstanceType KeyPairName: Ref: KeyPairName PublicSubnet1ID: Fn::GetAtt: - VPCStack - Outputs.PublicSubnet1ID PublicSubnet2ID: Fn::GetAtt: - VPCStack - Outputs.PublicSubnet2ID QSS3BucketName: Ref: QSS3BucketName QSS3BucketRegion: Ref: QSS3BucketRegion QSS3KeyPrefix: Fn::Sub: ${QSS3KeyPrefix}submodules/quickstart-linux-bastion/ RemoteAccessCIDR: Ref: RemoteAccessCIDR VPCID: Fn::GetAtt: - VPCStack - Outputs.VPCID DatabaseStack: Type: AWS::CloudFormation::Stack Properties: TemplateURL: !Sub - https://${S3Bucket}.s3.${S3Region}.${AWS::URLSuffix}/${QSS3KeyPrefix}templates/openedge-database.template.yaml - S3Region: !If [UsingDefaultBucket, !Ref 'AWS::Region', !Ref QSS3BucketRegion] S3Bucket: !If [UsingDefaultBucket, !Sub '${QSS3BucketName}-${AWS::Region}', !Ref QSS3BucketName] Parameters: DeployBucket: Ref: DeployBucket DeployBucketRegion: Ref: DeployBucketRegion EmailAddress: Ref: EmailAddress InstanceType: Ref: InstanceType KeyPairName: Ref: KeyPairName PrivateSubnet1ID: Fn::GetAtt: - VPCStack - Outputs.PrivateSubnet1AID PrivateSubnet2ID: Fn::GetAtt: - VPCStack - Outputs.PrivateSubnet2AID VPCID: Fn::GetAtt: - VPCStack - Outputs.VPCID PortNumber: Ref: PortNumber MinPort: Ref: MinPort MaxPort: Ref: MaxPort DBDeployPackage: Ref: DBDeployPackage PASOEStack: Type: AWS::CloudFormation::Stack Properties: TemplateURL: !Sub - https://${S3Bucket}.s3.${S3Region}.${AWS::URLSuffix}/${QSS3KeyPrefix}templates/openedge-pasoe.template.yaml - S3Region: !If [UsingDefaultBucket, !Ref 'AWS::Region', !Ref QSS3BucketRegion] S3Bucket: !If [UsingDefaultBucket, !Sub '${QSS3BucketName}-${AWS::Region}', !Ref QSS3BucketName] Parameters: DeployBucket: Ref: DeployBucket DeployBucketRegion: Ref: DeployBucketRegion EmailAddress: Ref: EmailAddress InstanceType: Ref: InstanceType KeyPairName: Ref: KeyPairName MinScalingInstances: Ref: MinScalingInstances MaxScalingInstances: Ref: MaxScalingInstances PrivateSubnet1ID: Fn::GetAtt: - VPCStack - Outputs.PrivateSubnet1AID PrivateSubnet2ID: Fn::GetAtt: - VPCStack - Outputs.PrivateSubnet2AID PublicSubnet1ID: Fn::GetAtt: - VPCStack - Outputs.PublicSubnet1ID PublicSubnet2ID: Fn::GetAtt: - VPCStack - Outputs.PublicSubnet2ID WebAccessCIDR: Ref: WebAccessCIDR VPCID: Fn::GetAtt: - VPCStack - Outputs.VPCID DBHostName: Fn::GetAtt: - DatabaseStack - Outputs.DBHostName DBHostName1: Fn::GetAtt: - DatabaseStack - Outputs.DBHostName1 DBHostName2: Fn::GetAtt: - DatabaseStack - Outputs.DBHostName2 PASOEDeployPackage: Ref: PASOEDeployPackage WebServerStack: Type: AWS::CloudFormation::Stack Properties: TemplateURL: !Sub - https://${S3Bucket}.s3.${S3Region}.${AWS::URLSuffix}/${QSS3KeyPrefix}templates/webserver.template.yaml - S3Region: !If [UsingDefaultBucket, !Ref 'AWS::Region', !Ref QSS3BucketRegion] S3Bucket: !If [UsingDefaultBucket, !Sub '${QSS3BucketName}-${AWS::Region}', !Ref QSS3BucketName] Parameters: DeployBucket: Ref: DeployBucket DeployBucketRegion: Ref: DeployBucketRegion EmailAddress: Ref: EmailAddress InstanceType: Ref: InstanceType KeyPairName: Ref: KeyPairName MinScalingInstances: Ref: MinScalingInstances MaxScalingInstances: Ref: MaxScalingInstances PrivateSubnet1ID: Fn::GetAtt: - VPCStack - Outputs.PrivateSubnet1AID PrivateSubnet2ID: Fn::GetAtt: - VPCStack - Outputs.PrivateSubnet2AID PublicSubnet1ID: Fn::GetAtt: - VPCStack - Outputs.PublicSubnet1ID PublicSubnet2ID: Fn::GetAtt: - VPCStack - Outputs.PublicSubnet2ID WebAccessCIDR: Ref: WebAccessCIDR VPCID: Fn::GetAtt: - VPCStack - Outputs.VPCID PASOEURL: Fn::GetAtt: - PASOEStack - Outputs.URL WebDeployPackage: Ref: WebDeployPackage Outputs: WebURL: Description: "The web server URL" Value: Fn::GetAtt: - WebServerStack - Outputs.URL PASOEURL: Description: "The PASOE URL" Value: Fn::GetAtt: - PASOEStack - Outputs.URL