-
Notifications
You must be signed in to change notification settings - Fork 208
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
Pod names are used instead of service names #71
Comments
If I remember correcly it was the result of a PR to fix headless services. I will look into this. |
Thanks for the quick resolution! |
@Gerrit-K @cjimti
Is it correct and necessary to automatically forward its first pod as a service name for a headless service? (Accessing nginx1 means accessing nginx-deployment-5cdfb5fc49-b44j2.nginx1) I will make changes if necessary. Looking forward to the reply. |
@calmkart yes to support 12-factor style development. When developing software locally the application may wish to point to a headless service (such as However, we also need to continue forwarding the individual Pods backing a headless service to be as flexible as possible. |
Sorry for the late response and thanks to both of you for revisiting and fixing this! |
tl;dr
Since version 1.8.2 kubefwd uses the pod names instead of the service names as hostnames
I used to use kubefwd 1.8.0 a lot for local development and embedded the service names in configs, e.g. the
redis
service oy my appacme
for the featurefeatxy
was forwarded according to the service namefeatxy-acme-redis
. Since upgrading to 1.8.4 (actually since 1.8.2 and later) /etc/hosts is populated with the pod names instead (e.g.featxy-acme-redis-57cbcdbd98
) which forces me to change all the configs if the pod gets a new identifier. Is this a bug or a feature?The text was updated successfully, but these errors were encountered: