Skip to content

Ingress: No healthy upstream for headless service #23182

@sayboras

Description

@sayboras

Is there an existing issue for this?

  • I have searched the existing issues

Reported by: @knfoo

What happened?

If the Ingress is configured with a headless service like below, the response from the Ingress route is coming back as no healthy upstream. Ideally, the request should be coming IP (which is specified in Endpoint object of the headless Service)

apiVersion: v1
kind: Service
metadata:
  name: details-headless
  namespace: default
spec:
  ports:
  - name: http
    port: 9080
    protocol: TCP
    targetPort: 9080
  clusterIP: None
  ipFamilies:
  - IPv4
  ipFamilyPolicy: SingleStack
---
apiVersion: v1
kind: Endpoints
metadata:
  name: details-headless
  namespace: default
subsets:
- addresses:
  - ip: 10.244.0.95 # manually configure this Endpoints resource with valid backend IP
  ports:
  - name: http
    port: 9080
    protocol: TCP
---
apiVersion: networking.k8s.io/v1
kind: Ingress
metadata:
  name: basic-ingress-headless
  namespace: default
spec:
  ingressClassName: cilium
  rules:
  - http:
      paths:
      - backend:
          service:
            name: details-headless
            port:
              number: 9080
        path: /details
        pathType: Prefix
---

Cilium Version

1.13.x
1.12.x

Kernel Version

N/A

Kubernetes Version

N/A

Sysdump

No response

Relevant log output

No response

Anything else?

No response

Code of Conduct

  • I agree to follow this project's Code of Conduct

Metadata

Metadata

Assignees

Labels

area/proxyImpacts proxy components, including DNS, Kafka, Envoy and/or XDS servers.area/servicemeshGH issues or PRs regarding servicemeshkind/bugThis is a bug in the Cilium logic.kind/community-reportThis was reported by a user in the Cilium community, eg via Slack.

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions