Skip to content

fix(pr-to-pr): Minor nginx fixup suggestion as proposed in review of #8821 - #8847

Merged
stasadev merged 1 commit into
ddev:20260913_stasadev_webserver_error_pagesfrom
rfay:20260913_stasadev_webserver_error_pages
Sep 22, 2026
Merged

stasadev merged 1 commit into
ddev:20260913_stasadev_webserver_error_pagesfrom
rfay:20260913_stasadev_webserver_error_pages

Conversation

@rfay

@rfay rfay commented Sep 22, 2026

Copy link
Copy Markdown
Member

If you like this, add it. It's the suggestion in the review.

@rfay
rfay requested a review from a team as a code owner September 22, 2026 16:12
@github-actions github-actions Bot added bugfix dependencies Pull requests that update a dependency file labels Sep 22, 2026
@github-actions

Copy link
Copy Markdown

Download this PR's build for your OS and architecture with:

ddev utility download-ddev --pr 8847

Or download the artifact for your OS and architecture directly:

See Testing a PR.

Open in GitHub Codespaces

@stasadev stasadev left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you!

@stasadev
stasadev merged commit a7c6a76 into ddev:20260913_stasadev_webserver_error_pages Sep 22, 2026
30 of 45 checks passed
@stasadev
stasadev deleted the 20260913_stasadev_webserver_error_pages branch September 22, 2026 16:31
@stasadev

Copy link
Copy Markdown
Member

It didn't help 🙁

https://github.com/ddev/ddev/actions/runs/35754704463/job/106837714929?pr=8821#step:7:7614

The only thing it fixed is an edge case with HTTP/2 200 where people have a custom .ddev/nginx_full/nginx-site.conf with a /ddev-webserver-403-error stanza.

But if you don't have the /ddev-webserver-403-error stanza in the file, it returns the default 403 from nginx.

@stasadev

Copy link
Copy Markdown
Member

Claude's answer:

  • Keeping a7c6a7692's version: breaks the 403 explanation for everyone on nginx-fpm, right now, in the common case (a no-index directory or a deny rule) — confirmed with a fresh container, no custom config involved at all. That's the entire point of this PR.
  • Reverting to the pre-fixup version: reintroduces the narrow edge case where a directory-listing-style 200 could show up instead of 403 — but only for someone who (a) hit the original pre-v1.25.4 bug, (b) still has ddev-webserver-403-error sitting in their own index list from that era, and (c) has taken ownership of .ddev/nginx_full/nginx-site.conf (removed #ddev-generated) so ddev start/ddev restart never regenerated it since. For anyone who hasn't disconnected from auto-regeneration, this doesn't come up at all — their config gets rewritten and stops referencing that path.

There's no clean nginx-native way to close that edge case without either duplicating the HTML page's content inline in the nginx config (which drifts from the Apache side and from the static file both webservers currently share), or the nested-error_page trick that just broke everything — I tried a plain two-hop chain with no return too, and nginx still won't do it: it 404s instead. rfay's own review called the edge case "fine, path forward is up to you," not a blocker — that was before it was known that "fixing" it breaks the primary path entirely.

stasadev added a commit that referenced this pull request Sep 22, 2026
rfay added a commit that referenced this pull request Sep 23, 2026
rfay pushed a commit that referenced this pull request Sep 23, 2026
rfay added a commit that referenced this pull request Sep 23, 2026
rfay pushed a commit that referenced this pull request Sep 23, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bugfix dependencies Pull requests that update a dependency file

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants