aws上负载均衡器标组端口_AWS CloudFormation:目标组没有关联的负载均衡器
aws上負(fù)載均衡器標(biāo)組端口
昨天,我使用AWS CloudFormation模板最終創(chuàng)建了ECS服務(wù)(Fargate類型),還創(chuàng)建了包括應(yīng)用程序負(fù)載均衡器,目標(biāo)組和IAM角色的資源。
創(chuàng)建堆棧時,出現(xiàn)以下錯誤:
具有targetGroupArn arn:aws:elasticloadbalancing:us-east-1:599074885545:targetgroup / a204516-S2S-Sandbox-TargetGroup / 9f4aa2eb4051a952的目標(biāo)組沒有關(guān)聯(lián)的負(fù)載均衡器。 (服務(wù):AmazonECS;狀態(tài)代碼:400;錯誤代碼:InvalidParameterException;請求ID:5da2a1ed-a216-4666-a6f9-8af18ef37af6)
The target group with targetGroupArn arn:aws:elasticloadbalancing:us-east-1:999999995545:targetgroup/MyTargetGroup/999999eb4051a952 does not have an associated load balancer. (Service: AmazonECS; Status Code: 400; Error Code: InvalidParameterException; Request ID: 54321987-a2a2-4444-abcd-8af18ef12345)我檢查了我的模板很多次,并認(rèn)為它是正確的。 我在論壇上發(fā)現(xiàn)了一條帖子,提示該錯誤可能是由于創(chuàng)建ECS服務(wù)時可能尚未創(chuàng)建負(fù)載均衡器。
解決方案:將DependsOn屬性用于ECS服務(wù)資源。
這是我的AWS CloudFormation模板的一部分,使用DependsOn屬性:
#Create Application Load Balancer DemoApplicationLoadBalancer: Type: AWS::ElasticLoadBalancingV2::LoadBalancer Properties: Type: application Name: Demo-ALB IpAddressType: ipv4 Scheme: internet-facing # Other properties... # Create Security Groups, IAM Roles, Load Balancing Listener, ECS Cluster, ECS Task Def, etc. # Create ECS Service - with DependsOn attribute DemoSandboxService: Type: AWS::ECS::Service DependsOn: - DemoLoadBalancerListener Properties: Cluster: Ref: DemoSandboxCluster # Other properties...翻譯自: https://www.javacodegeeks.com/2020/06/aws-cloudformation-target-group-does-not-have-an-associated-load-balancer.html
aws上負(fù)載均衡器標(biāo)組端口
總結(jié)
以上是生活随笔為你收集整理的aws上负载均衡器标组端口_AWS CloudFormation:目标组没有关联的负载均衡器的全部內(nèi)容,希望文章能夠幫你解決所遇到的問題。
- 上一篇: ai怎么渐变不了(ai怎么渐变不了有禁止
- 下一篇: HttpClient 4 API –获取