aws elbv2 create-load-balancer --name YOUR-INTERNAL-LOAD-BALANCER-NAME \
--type network --scheme internal --subnets subnet-XXXXXXXX
aws elbv2 create-target-group --name YOUR-TARGET-GROUP-NAME \
--protocol TCP --port 80 \
--vpc-id YOUR-VPC-ID \
--health-check-interval-seconds 10 \
--health-check-protocol HTTP --health-check-path /
aws elbv2 register-targets --target-group-arn YOUR-TARGET-GROUP-ARN \
--targets Id=i-XXX Id=i-YYY ...
aws elbv2 create-listener --load-balancer-arn YOUR-INTERNAL-LOAD-BALANCER-ARN \
--protocol TCP --port 80 \
--default-actions Type=forward,TargetGroupArn=YOUR-TARGET-GROUP-ARN
上一篇:AWS内部负载均衡器的SSL证书
下一篇:AWS内联策略中的动态用户名