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

regression in 2.8 file_server serving root index file #6358

Closed
willnorris opened this issue Jun 1, 2024 · 3 comments
Closed

regression in 2.8 file_server serving root index file #6358

willnorris opened this issue Jun 1, 2024 · 3 comments
Labels
duplicate 🖇️ This issue or pull request already exists

Comments

@willnorris
Copy link
Contributor

caddy 2.8 seems to be failing to serve a root /index.html page as I would expect.

Reproduction case

Create index.html file: echo Hello > index.html

Create Caddyfile:

{
  debug
}

:8080 {
  file_server
  try_files {path} {path}/ =404
}

On caddy 2.7, http://localhost:8080/ will load the index.html page and serve "Hello". On caddy 2.8, it returns an empty 404 error. If there is a sub directory like http://localhost:8080/sub/ then the index page loads fine. It is only for the root URL.

@mohammed90
Copy link
Member

Do you think it's the same as #6352?

@willnorris
Copy link
Contributor Author

ah, yes. This definitely seems to be the same. The same commit identified there, 6d97d8d, seems to be where the issue lies. I'll close this as a dup of #6352 and see if I can help debug the issue over there.

@mohammed90 mohammed90 added the duplicate 🖇️ This issue or pull request already exists label Jun 1, 2024
@mholt
Copy link
Member

mholt commented Jun 2, 2024

Thanks so much for debugging this before I even had a chance to sit down to look at it! 😄

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
duplicate 🖇️ This issue or pull request already exists
Projects
None yet
Development

No branches or pull requests

3 participants