MeBNoah
MeBNoah

Reputation: 185

Traefik as Kubernetes Ingress on Azure - Assign static IP to Traefik service

I am trying to use Traefik as a Kubernetes Ingress on Azure Kubernetes Service. While there are docs that provide information on how to do that with Kubernetes Ingress, I cannot find information about how to do that with Traefik Ingress.

Has anyone out there achieved that and can help?

PS. I am using Helm to install Traefik

Upvotes: 1

Views: 2143

Answers (2)

MeBNoah
MeBNoah

Reputation: 185

In the meanwhile I found it, so I am going to answer my own question.

Like @mashov said you need

service:
  spec:
  loadBalancerIP: YOURIP

But also you need to add the following annotation

service:
  spec:
  annotations:
  "service.beta.kubernetes.io/azure-load-balancer-resource-group": "Resource Group that contains public IP"

Therefore your AKS identity needs to have the role "Network Contributor" on the resource group that holds the public IP

Upvotes: 4

mashov
mashov

Reputation: 21

Before, you must create an Public IP.

And after, in values.yml file, you assign your IP:

service:
  spec:
    loadBalancerIP: YOURIP

Upvotes: 2

Related Questions