Skip to content

Commit

Permalink
Merge pull request #126 from RLOpenCatalyst/feat-hms-byon
Browse files Browse the repository at this point in the history
feat: Added support for multiple ALBs
  • Loading branch information
srpiatt authored Sep 28, 2023
2 parents 535057c + 54dfff0 commit 04e8226
Show file tree
Hide file tree
Showing 29 changed files with 11,992 additions and 11,596 deletions.
74 changes: 74 additions & 0 deletions .pnpm-debug.log
Original file line number Diff line number Diff line change
@@ -0,0 +1,74 @@
{
"0 debug pnpm:scope": {
"selected": 60,
"total": 60,
"workspacePrefix": "/home/manikanddan/Mani/code/aws_swb/SWB-HMS/service-workbench-on-aws"
},
"1 debug pnpm:lifecycle": {
"depPath": "/home/manikanddan/Mani/code/aws_swb/SWB-HMS/service-workbench-on-aws/addons/addon-base-raas/packages/base-raas-cfn-templates",
"optional": false,
"script": "pnpm run babel",
"stage": "build",
"wd": "/home/manikanddan/Mani/code/aws_swb/SWB-HMS/service-workbench-on-aws/addons/addon-base-raas/packages/base-raas-cfn-templates"
},
"2 debug pnpm:lifecycle": {
"depPath": "/home/manikanddan/Mani/code/aws_swb/SWB-HMS/service-workbench-on-aws/addons/addon-base-raas/packages/base-raas-cfn-templates",
"line": "> @aws-ee/base-raas-cfn-templates@1.0.0 babel /home/manikanddan/Mani/code/aws_swb/SWB-HMS/service-workbench-on-aws/addons/addon-base-raas/packages/base-raas-cfn-templates",
"stage": "build",
"stdio": "stdout",
"wd": "/home/manikanddan/Mani/code/aws_swb/SWB-HMS/service-workbench-on-aws/addons/addon-base-raas/packages/base-raas-cfn-templates"
},
"3 debug pnpm:lifecycle": {
"depPath": "/home/manikanddan/Mani/code/aws_swb/SWB-HMS/service-workbench-on-aws/addons/addon-base-raas/packages/base-raas-cfn-templates",
"line": "> babel src/ --out-dir dist/ --source-maps",
"stage": "build",
"stdio": "stdout",
"wd": "/home/manikanddan/Mani/code/aws_swb/SWB-HMS/service-workbench-on-aws/addons/addon-base-raas/packages/base-raas-cfn-templates"
},
"4 debug pnpm:lifecycle": {
"depPath": "/home/manikanddan/Mani/code/aws_swb/SWB-HMS/service-workbench-on-aws/addons/addon-base-raas/packages/base-raas-cfn-templates",
"line": "sh: 1: babel: not found",
"stage": "build",
"stdio": "stderr",
"wd": "/home/manikanddan/Mani/code/aws_swb/SWB-HMS/service-workbench-on-aws/addons/addon-base-raas/packages/base-raas-cfn-templates"
},
"5 debug pnpm:lifecycle": {
"depPath": "/home/manikanddan/Mani/code/aws_swb/SWB-HMS/service-workbench-on-aws/addons/addon-base-raas/packages/base-raas-cfn-templates",
"line": " ERROR  Command failed.",
"stage": "build",
"stdio": "stdout",
"wd": "/home/manikanddan/Mani/code/aws_swb/SWB-HMS/service-workbench-on-aws/addons/addon-base-raas/packages/base-raas-cfn-templates"
},
"6 debug pnpm:lifecycle": {
"depPath": "/home/manikanddan/Mani/code/aws_swb/SWB-HMS/service-workbench-on-aws/addons/addon-base-raas/packages/base-raas-cfn-templates",
"exitCode": 1,
"optional": false,
"stage": "build",
"wd": "/home/manikanddan/Mani/code/aws_swb/SWB-HMS/service-workbench-on-aws/addons/addon-base-raas/packages/base-raas-cfn-templates"
},
"7 info pnpm": {
"err": {
"name": "Error",
"message": "@aws-ee/base-raas-cfn-templates@1.0.0 build: `pnpm run babel`\nExit status 1",
"code": "ELIFECYCLE",
"stack": "Error: @aws-ee/base-raas-cfn-templates@1.0.0 build: `pnpm run babel`\nExit status 1\n at EventEmitter.<anonymous> (/usr/local/lib/node_modules/pnpm/dist/pnpm.js:102608:18)\n at EventEmitter.emit (node:events:513:28)\n at ChildProcess.<anonymous> (/usr/local/lib/node_modules/pnpm/dist/pnpm.js:87658:16)\n at ChildProcess.emit (node:events:513:28)\n at maybeClose (node:internal/child_process:1100:16)\n at Process.ChildProcess._handle.onexit (node:internal/child_process:304:5)"
}
},
"8 error pnpm": {
"message": {
"errno": 1,
"code": "ERR_PNPM_RECURSIVE_RUN_FIRST_FAIL",
"pkgid": "@aws-ee/base-raas-cfn-templates@1.0.0",
"stage": "build",
"script": "pnpm run babel",
"pkgname": "@aws-ee/base-raas-cfn-templates",
"prefix": "/home/manikanddan/Mani/code/aws_swb/SWB-HMS/service-workbench-on-aws/addons/addon-base-raas/packages/base-raas-cfn-templates"
},
"err": {
"name": "Error",
"message": "@aws-ee/base-raas-cfn-templates@1.0.0 build: `pnpm run babel`\nExit status 1",
"code": "ERR_PNPM_RECURSIVE_RUN_FIRST_FAIL",
"stack": "Error: @aws-ee/base-raas-cfn-templates@1.0.0 build: `pnpm run babel`\nExit status 1\n at EventEmitter.<anonymous> (/usr/local/lib/node_modules/pnpm/dist/pnpm.js:102608:18)\n at EventEmitter.emit (node:events:513:28)\n at ChildProcess.<anonymous> (/usr/local/lib/node_modules/pnpm/dist/pnpm.js:87658:16)\n at ChildProcess.emit (node:events:513:28)\n at maybeClose (node:internal/child_process:1100:16)\n at Process.ChildProcess._handle.onexit (node:internal/child_process:304:5)"
}
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
{
"0 debug pnpm:scope": {
"selected": 1,
"workspacePrefix": "/home/manikanddan/Mani/code/aws_swb/SWB-HMS/service-workbench-on-aws"
},
"1 error pnpm": {
"message": {
"code": "ELIFECYCLE",
"errno": "ENOENT",
"syscall": "spawn",
"file": "sh",
"pkgid": "@aws-ee/base-raas-cfn-templates@1.0.0",
"stage": "babel",
"script": "babel src/ --out-dir dist/ --source-maps",
"pkgname": "@aws-ee/base-raas-cfn-templates"
},
"err": {
"name": "Error",
"message": "@aws-ee/base-raas-cfn-templates@1.0.0 babel: `babel src/ --out-dir dist/ --source-maps`\nspawn ENOENT",
"code": "ELIFECYCLE",
"stack": "Error: @aws-ee/base-raas-cfn-templates@1.0.0 babel: `babel src/ --out-dir dist/ --source-maps`\nspawn ENOENT\n at ChildProcess.<anonymous> (/usr/local/lib/node_modules/pnpm/dist/pnpm.js:87651:20)\n at ChildProcess.emit (node:events:513:28)\n at maybeClose (node:internal/child_process:1100:16)\n at Process.ChildProcess._handle.onexit (node:internal/child_process:304:5)"
}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -7,53 +7,65 @@ Parameters:
VPC:
Description: The VPC in which the EC2 instance will reside
Type: AWS::EC2::VPC::Id
Subnet1:
Description: The VPC subnet in which the EC2 instance will reside
ALBSubnet1:
Description: The VPC subnet 1 in which the Application load Balancer will reside
Type: AWS::EC2::Subnet::Id
ALBSubnet2:
Description: The VPC subnet 2 in which the Application load Balancer will reside
Type: AWS::EC2::Subnet::Id
LoadBalancerType:
Description: Type of ALB (internal or internet-facing)
Type: String
ACMSSLCertARN:
Type: String
Description: The ARN of the AWS Certificate Manager SSL Certificate to associate with the Load Balancer
IsAppStreamEnabled:
Type: String
AllowedValues: [true, false]
Description: Is AppStream enabled for this workspace
AppStreamSG:
Type: String
Description: AppStream Security Group ID
PublicRouteTableId:
Type: String
Description: Public Route Table ID
LoggingBucket:
Type: String
Description: Bucket for ELB Logs

Resources:
ALBSubnet:
Type: AWS::EC2::Subnet
Properties:
VpcId: !Ref VPC
CidrBlock: 10.0.32.0/19
AvailabilityZone: us-east-1b
ALBListener:
Type: AWS::ElasticLoadBalancingV2::Listener
Properties:
DefaultActions:
- Type: fixed-response
FixedResponseConfig:
ContentType: "text/plain"
MessageBody: "Forbidden"
StatusCode: "403"
LoadBalancerArn:
Ref: ApplicationLoadBalancer
Port: 443
Protocol: HTTPS
SslPolicy: ELBSecurityPolicy-2016-08
Certificates:
- CertificateArn: !Ref ACMSSLCertARN
Type: AWS::ElasticLoadBalancingV2::Listener
Properties:
DefaultActions:
- Type: fixed-response
FixedResponseConfig:
ContentType: "text/plain"
MessageBody: "Forbidden"
StatusCode: "403"
LoadBalancerArn:
Ref: ApplicationLoadBalancer
Port: 443
Protocol: HTTPS
SslPolicy: ELBSecurityPolicy-2016-08
Certificates:
- CertificateArn: !Ref ACMSSLCertARN
ApplicationLoadBalancer:
Type: AWS::ElasticLoadBalancingV2::LoadBalancer
Properties:
Name: !Ref Namespace
Scheme: internet-facing # or internal
Scheme: !Ref LoadBalancerType
Subnets:
- Ref: Subnet1
- Ref: ALBSubnet
SecurityGroups:
- Ref: ALBSecurityGroup
- Ref: ALBSubnet1
- Ref: ALBSubnet2
SecurityGroups:
- Ref: ALBSecurityGroup
ALBSecurityGroup:
Type: AWS::EC2::SecurityGroup
Properties:
SecurityGroupIngress:
- CidrIp: "0.0.0.0/0"
FromPort: 443
ToPort: 443
IpProtocol: tcp
IpProtocol: "-1"
GroupDescription: ALB SecurityGroup
VpcId: !Ref VPC
Outputs:
Expand All @@ -65,4 +77,7 @@ Outputs:
Value: !GetAtt ApplicationLoadBalancer.DNSName
ListenerArn:
Description: ARN of Application Load Balancer Listener
Value: !Ref ALBListener
Value: !Ref ALBListener
ALBSecurityGroupId:
Description: Security Group of Application Load Balancer Listener
Value: !Ref ALBSecurityGroup
Original file line number Diff line number Diff line change
Expand Up @@ -165,6 +165,7 @@ function getStaticSettings(existingStaticSettings, settings, pluginRegistry) {
table('dbEgressStore', 'EgressStore');
table('StorageGateway', 'StorageGateway');
table('dbDeploymentStore', 'DeploymentStore');
table('dbLoadBalancers', 'LoadBalancers');

return staticSettings;
}
Expand Down
Loading

0 comments on commit 04e8226

Please sign in to comment.