I can find the loadbalancer URL manually:
> LOAD_BALANCER_URL=`kubectl describe service leafsheets-django-service-staging --namespace=$K8S_NAMESPACE | grep "${AWS_REGION}.elb.amazonaws.com*" | awk '{print $3}'`
> echo $LOAD_BALANCER_URL
sample output from kubectl describe
command
> kubectl describe service leafsheets-django-service-staging --namespace=leafsheets-staging
Name: leafsheets-django-service-staging
Namespace: leafsheets-staging
Labels: <none>
Annotations: <none>
Selector: pod=leafsheets-staging-django
Type: LoadBalancer
IP: 10.100.13.121
LoadBalancer Ingress: aa13d515171d045319aaf59e9d08e2a5-1015643832.us-west-2.elb.amazonaws.com
Port: http 80/TCP
TargetPort: 8000/TCP
NodePort: http 32567/TCP
Endpoints: 192.168.93.189:8000
Port: https 443/TCP
TargetPort: 8000/TCP
NodePort: https 30041/TCP
Endpoints: 192.168.93.189:8000
Session Affinity: None
External Traffic Policy: Cluster
Events: <none>
... but how to find the associated HostedZoneId?
I can hardcode it:
# https://docs.aws.amazon.com/general/latest/gr/elb.html
HOSTED_ZONE_ID=Z1H1FL5HABSF5
... but I'd prefer to deduce it.