Can you get the AWS LB Pulumi object from an `k8s....
# general
f
Can you get the AWS LB Pulumi object from an
k8s.core.v1.Service
?
w
This has come up before - and as far as I can tell Kubernetes does not provide any way to retrieve this. If others have figured out how to do it - I'd love to hear.
c
No, and this is a platform choice from AWS, which could provide a custom controller for htis.
s
i’ve just checked one
LoadBalancer
svc in our cluster, and you should be able to get lb dns record from
status.loadBalancer.ingress[0].hostname
not sure if this field is accessible in pulumi though
c
the file?
s
Sorry, typo, I meant
field
w
Ahh - yes - if I recall correctly the problem is that AWS does not offer any API to lookup LoadBalancer's by hostname, so although you know the hostname, the only way to get back the identity of the loadbalancer would be to list all loadbalancers and filter down. That's possible, but somewhat involved. What Kubernetes should do is record the ARN or
name
of the loadbalancer so that it can be looked up.
c
yes, that’s right.