Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add dependson to alb #149

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open

Conversation

hqtan
Copy link

@hqtan hqtan commented Aug 28, 2023

Purpose of PR

This PR proposes a fix to an issue that was reported in slack:
https://techstudyslack.slack.com/archives/C010173PTGU/p1693031828964669

The issue was encountered during deployment of ALBSTICKINESS.yaml stack, with the following error message:

VPC has no internet gateway (Service: AmazonElasticLoadBalancing; Status Code: 400; Error Code: InvalidSubnet

the ALB resource in the stack fails to deploy, because the InternetGatewayAttachment resource wasn't being created before the ALB resource.

Proposed fix to issue

The proposed fix to this issue is to add a DependsOn: InternetGatewayAttachment attribute to the ALB resource to add InternetGatewayAttachment resource as a dependency for ALB resource.

N.B:
Also included a minor improvement to stack template, suggested by cfn-lint tool, to remove the use of !Sub intrinsic function from UserData attribute in WEBLaunchTemplate resource.

apply a `cfn-lint` suggestion: 
```
W1020 Fn::Sub isn't needed because there are no variables at Resources/WEBLaunchTemplate/Properties/LaunchTemplateData/UserData/Fn::Base64/Fn::Sub
```
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant