Kubernetes ingress for leader follower system

0 votes

I have a kubernetes service that works in a leader/follower fashion, so only one of 2 pods can accept the connection. I want to make my service publicly available with traefik ingress controller.

Oct 1, 2018 in Kubernetes by lina
• 8,100 points
21 views

1 answer to this question.

0 votes

you can use a traefik backend health check defined in your k8s ingress through annotations. This way you don't forward to backends that are not active. For example:

kind: Ingress
metadata:
  name: specific-deployment
  annotations:
    traefik.backend.healthcheck.port: 8080
    traefik.backend.healthcheck.scheme: http
    traefik.backend.healthcheck.path: /health   
spec:
  rules:
  - host: specific.minikube
    http:
      paths:
      - path: /
        backend:
          serviceName: stilton
          servicePort: http

This way you can use the k8s readiness probes for your pods.

answered Oct 1, 2018 by Kalgi
• 37,320 points

Related Questions In Kubernetes

0 votes
1 answer

Forcing ssl for Kubernetes Ingress on GKE

https://github.com/kubernetes/ingress-gce#frontend-https If you want to block http, you ...READ MORE

answered Sep 6, 2018 in Kubernetes by ajs3033
• 7,240 points
919 views
0 votes
1 answer

Kubernetes Ingress controllers for wildcard url mapping

If you use the stock controllers you ...READ MORE

answered Sep 10, 2018 in Kubernetes by Kalgi
• 37,320 points
592 views
0 votes
1 answer

Defining a fallback service for Kubernetes ingress

For the Nginx Ingress Controller there is ...READ MORE

answered Sep 11, 2018 in Kubernetes by Kalgi
• 37,320 points
181 views
0 votes
1 answer

Disable SSL redirect for Kubernetes NGINX ingress

Adding ingress.kubernetes.io/ssl-redirect: "false" to annotations will disable the SSL redirect: apiVersion: extensions/v1beta1 kind: ...READ MORE

answered Sep 12, 2018 in Kubernetes by Kalgi
• 37,320 points
1,238 views
0 votes
1 answer
0 votes
1 answer

permissions related to AWS ECR

if you add allowContainerRegistry: true, kops will add those permissions ...READ MORE

answered Oct 9, 2018 in Kubernetes by Kalgi
• 37,320 points
48 views
0 votes
3 answers

Error while joining cluster with node

Hi Kalgi after following above steps it ...READ MORE

answered Jan 17 in Others by anonymous
1,134 views
0 votes
2 answers

single point of entry for multiple services in kubernetes ingress

I tried having something similar too. Deployment apiVersion: extensions/v1beta1 kind: ...READ MORE

answered Sep 7, 2018 in Kubernetes by Hannah
• 14,080 points
87 views
0 votes
1 answer

ingress for kubernetes wordpress

You can configure your ingress to forward ...READ MORE

answered Sep 7, 2018 in Kubernetes by Kalgi
• 37,320 points
216 views