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
feat: Use container names for upstream names to avoid repeats #1938
base: main
Are you sure you want to change the base?
Conversation
I'm on it: #1940 |
Thanks for updating docker-gen. I rebased and switched to the |
Thanks for the PR, unfortunately we can't make this behaviour a default one because a lot of people have custom configurations that rely on upstream names being equal to the hostnames. See #1725, #1693 (comment), #1736 plus the release notes of version |
I updated the PR to keep the current behavior by default. |
Friendly ping @buchdag |
75c1402
to
b5da566
Compare
Marking as draft until #2127 is merged. |
8554677
to
2664d2a
Compare
f9a01fe
to
d9b6c54
Compare
f427fdd
to
78c82e9
Compare
cddce7f
to
eef4e4a
Compare
dc6fa03
to
8db5b82
Compare
@rhansen sorry for the incredibly long delay on this one. I've tested the PR, and I'm still a bit confused about it. Does it provide any advantage / behaviour change when not using What kind of issue could the "repeat" of upstreams when using I feel like I'm completely missing the point but I seem unable to grasp what issue this PR is attempting to solve or its benefits against its non trivial added complexity. 🤔 I also don't think it could realistically be made default as it would made upstream name somewhere between very hard to predict and unpredictable on systems or setups where container names are dynamically generated or containers replica dynamically started / stopped. |
Yes. Currently, if a single container is used for multiple vhosts (e.g.,
I think the repeated upstreams could theoretically cause minor load balancing issues.
It's been a year so a lot has slipped away from memory, but IIRC my main motivation was to facilitate a fix for #1504. Give me some time to recall what I was doing and I'll update the commit message with some rationale.
Hmm, that's a good point. Let me think about this some more to see if there's a good general solution that checks all of these boxes:
|
Note: This depends on PR #2127, and will be marked as draft until that PR is merged.