Skip to content

allow dynamic ip resolve on php handler #2413

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

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

SebastianRzk
Copy link

Problem:

When using upstream in the nginx config, the ip for app is resolved once. So if the app container gets updated (e.g. through watchtower, the ip changes and the server php-handler is not reachable anymore.

Fix:

  • Add docker dns as resovler
  • replace upstream with variable (set), to trigger the dns lookup

Source / Inspiration:

bug on the watchtower github

Signed-off-by: SebastianRzk <github@sebastianruziczka.de>
@J0WI
Copy link
Contributor

J0WI commented Apr 18, 2025

We use to copy the example from https://github.com/nextcloud/documentation/blob/master/admin_manual/installation/nginx-root.conf.sample and apply fixes directly in the upstream documentation.

This is an edge case as it affects only the very specific case with nginx and backends running as container but it's not specific to Nextcloud. The examples are not meant to be production ready configurations but they make it easier to develop a custom configuration. I'm undecided whether it's worth to cover this in the examples or just refer to the documentation and examples of nginx.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants