Skip to content

Commit

Permalink
add exception if https does not exist
Browse files Browse the repository at this point in the history
  • Loading branch information
davidsiaw committed Sep 7, 2023
1 parent 7b95811 commit 9d2d730
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion app/models/backend/ecs/v2/service_stack.rb
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,11 @@ class Builder < CloudFormation::Builder
def build_resources
deps = []
if use_alb?
deps = ['LBListenerRuleHTTP', 'LBListenerRuleHTTPS']
deps = ['LBListenerRuleHTTP']

if listener&.endpoint&.https_listener_id&.present?
deps << 'LBListenerRuleHTTPS'
end
end

add_resource("AWS::ECS::Service", "ECSService", { depends_on: deps }) do |j| j.Cluster district.name
Expand Down

0 comments on commit 9d2d730

Please sign in to comment.