contour: Address not set on Ingress resource
Contour does not set the IP value on the Ingress resource. This value is necessary for services like ExternalDNS to work properly.
Version
The version that https://j.hept.io/contour-deployment-norbac
produces. Atm:
docker.io/envoyproxy/envoy-alpine:v1.6.0
gcr.io/heptio-images/contour:master (pointing to b9ede01f025
)
Repro
- Setup Contour in your cluster.
kubectl apply -f kubectl apply -f https://j.hept.io/contour-deployment-norbac
- Deploy a simple service with Ingress rules.
kubectl apply -f https://gist.githubusercontent.com/nphmuller/1c980c72e2119b1482e19eb619def08f/raw/10331f4bbc18abe36a0c8c841bf70ab04a38eb92/service-with-ingress.yaml
- (A)
kubectl get ingress nginx
- (B)
kubectl get ingress nginx -o yaml
Expected
A. ADDRESS column should have external IP of Contour load balancer service, but is empty. B. status should have value:
status:
loadBalancer:
ingress:
- ip: %External IP-of-Contour-LoadBalancer-service%
but has value:
status:
loadBalancer: {}
About this issue
- Original URL
- State: closed
- Created 6 years ago
- Reactions: 16
- Comments: 16 (12 by maintainers)
Commits related to this issue
- design: add draft for ingress status loadbalancer support Updates #403 Strawman design for supporting the ingress.status.loadbalancer field. Signed-off-by: Dave Cheney <dave@cheney.net> — committed to davecheney/contour by davecheney 4 years ago
- design: add draft for ingress status loadbalancer support Updates #403 Strawman design for supporting the ingress.status.loadbalancer field. Signed-off-by: Dave Cheney <dave@cheney.net> — committed to davecheney/contour by davecheney 4 years ago
- design: add draft for ingress status loadbalancer support Updates #403 Strawman design for supporting the ingress.status.loadbalancer field. Signed-off-by: Dave Cheney <dave@cheney.net> — committed to projectcontour/contour by davecheney 4 years ago
- internal/dag: move extension ingress translation to a helper Updates #403 Prior to this PR the automagic translation of the deprecated extensions/ingress.v1beta1 types to networking/ingress.v1beta1 ... — committed to davecheney/contour by davecheney 4 years ago
- internal/dag: move extension ingress translation to a helper Updates #403 Prior to this PR the automagic translation of the deprecated extensions/ingress.v1beta1 types to networking/ingress.v1beta1 ... — committed to davecheney/contour by davecheney 4 years ago
- cmd/contour: remove leadership-deposed worker Updates #403 Combine the leadership elected and deposed workers. Signed-off-by: Dave Cheney <dave@cheney.net> — committed to projectcontour/contour by davecheney 4 years ago
- cmd/contour: update leadership election logger context Updates #403 Update logger context after offline feedback. Signed-off-by: Dave Cheney <dave@cheney.net> — committed to davecheney/contour by davecheney 4 years ago
- cmd/contour: update leadership election logger context Updates #403 Update logger context after offline feedback. Signed-off-by: Dave Cheney <dave@cheney.net> — committed to projectcontour/contour by davecheney 4 years ago
- cmd/contour: unify client creation Updates #403 Before I can add ingress status support to cmd/contour I need to clean up the serve method. This change unifies the creation of the various clients to... — committed to davecheney/contour by davecheney 4 years ago
- cmd/contour: unify client creation Updates #403 Before I can add ingress status support to cmd/contour I need to clean up the serve method. This change unifies the creation of the various clients to... — committed to davecheney/contour by davecheney 4 years ago
- cmd/contour: unify client creation Updates #403 Before I can add ingress status support to cmd/contour I need to clean up the serve method. This change unifies the creation of the various clients to... — committed to davecheney/contour by davecheney 4 years ago
- cmd/contour: unify client creation Updates #403 Before I can add ingress status support to cmd/contour I need to clean up the serve method. This change unifies the creation of the various clients to... — committed to projectcontour/contour by davecheney 4 years ago
- internal/k8s: simplify DyanmicConverter Updates #403 Currently in cmd/contour.doServe we have three ResourceEventHandler types defined; - eventHandler, which is the internal/contour.EventHandler co... — committed to davecheney/contour by davecheney 4 years ago
- internal/k8s: simplify DynamicConverter Updates #403 Currently in cmd/contour.doServe we have three ResourceEventHandler types defined; - eventHandler, which is the internal/contour.EventHandler co... — committed to davecheney/contour by davecheney 4 years ago
- internal/k8s: simplify DynamicConverter Updates #403 Currently in cmd/contour.doServe we have three ResourceEventHandler types defined; - eventHandler, which is the internal/contour.EventHandler co... — committed to projectcontour/contour by davecheney 4 years ago
- cmd/contour: connect all informers to the dynamicHandler Updates #403 wasn't an unstructured.Unstructured type. This allows us to send all the traffic through the DynamicConverter, removing the even... — committed to davecheney/contour by davecheney 4 years ago
- cmd/contour: connect all informers to the dynamicHandler Updates #403 wasn't an unstructured.Unstructured type. This allows us to send all the traffic through the DynamicConverter, removing the even... — committed to projectcontour/contour by davecheney 4 years ago
- cmd/contour: simplify leadership election setup Updates #403 Ingress status updates depend on leadership election. This PR moves leadership setup outside doServe and simplifies the interaction with ... — committed to davecheney/contour by davecheney 4 years ago
- cmd/contour: simplify leadership election setup Updates #403 Ingress status updates depend on leadership election. This PR moves leadership setup outside doServe and simplifies the interaction with ... — committed to projectcontour/contour by davecheney 4 years ago
- cmd/contour: add IngressStatusWriter Updates #403 This PR adds a worker to doServe's group which writes back load balancer status to ingress.v1beta1 objects. In this PR, the population of the isw.l... — committed to davecheney/contour by davecheney 4 years ago
I was going to pick this up, my thought here was to do the following:
This assumption also assumes there’s only one service in the namespace where Contour is deployed that is type
LoadBalancer
. We could also filter on the service nameenvoy
, but not sure if that’s too specific.The status should also only get updated if the ingress class matches the Ingress resource.
This should be possible to cover as part of the IngressRoute refactor. No ETA on a milestone.
Just to provide an update aside from commit messages:
The main part of this work is complete for the example deployment - Contour will now look for the Envoy service and expose the IP from its Loadbalancer-type Service in Ingress records that are in scope.
The last piece is to complete #2387, allowing manual specification of the details rather than pulling them from a Service.
I’m picking this up now that Dave has left the team.
The current design of this has taken a lot of cues from the nginx-ingress-controller, speficially the
--update-status
,--publish-service
, and--publish-status-address
, see the command line reference.Contour’s current design is as follows:
envoy
service in ProjectContour for the load balancer address, and sends it down the channel to IngressStatusWriter. This is configured with via command-line flags, with defaults to the example deployment.Todo:
Done:
@stevesloka Probably worth doing a small prior art survey to see how other ingress controllers solve this problem. IIRC ingress-nginx uses a command flag.