Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Kubernetes provider: should allow the master url to be override #501

Closed
javefang opened this issue Jul 7, 2016 · 3 comments
Closed

Kubernetes provider: should allow the master url to be override #501

javefang opened this issue Jul 7, 2016 · 3 comments
Labels

Comments

@javefang
Copy link

javefang commented Jul 7, 2016

When using Traefik with Kubernetes, there are currently 3 ways to define where the Kubernetes api server is running:

  1. Environment variable: KUBERNETES_SERVICE_HOST
  2. The "/etc/traefik/traefik.toml" config file
  3. The "--kubernetes.endpoint" command line parameter

Currently 1 seems to be used as a priority, regardless of what value is set in 2 or 3. I think the correct priority should be 3(command line) > 2 (config) > 1 (default env var).

@javefang
Copy link
Author

javefang commented Jul 7, 2016

I think Kubernetes also has a bug related to this. People who want to use Traefik with high availability kubernetes master should either

  1. Override the kube apiserver url in Traefik config with the load balancer's URL
  2. Wait for this issue to be fixed kube-apiserver endpoint cleanup when --apiserver-count>1 kubernetes/kubernetes#22609

@errm
Copy link
Contributor

errm commented Jul 8, 2016

Yes that sounds reasonable to me.

It might be possible to work around by setting KUBERNETES_SERVICE_HOST in your Traefik PodSpec . . . but perhaps not, I haven't tried.

@errm errm added the kind/enhancement a new or improved feature. label Jul 8, 2016
@javefang
Copy link
Author

@errm thanks, I tried, but doesn't seem to work correctly... (i.e. it's not calling the URLs set by the env var)

@traefik traefik locked and limited conversation to collaborators Sep 1, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

No branches or pull requests

3 participants