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

__PATH_PREFIX__ in URL path and get a 404 error on root page #1490

Closed
zhazell opened this issue Jan 3, 2025 · 2 comments
Closed

__PATH_PREFIX__ in URL path and get a 404 error on root page #1490

zhazell opened this issue Jan 3, 2025 · 2 comments

Comments

@zhazell
Copy link

zhazell commented Jan 3, 2025

Describe the bug
BASE_PATH is not defined and is blank in docker container. Using a reverse proxy to proxy connection to Maintainerr. When browsing the root https://maintainer.example.com, I get a 404 error on the main page.
Screenshot 2025-01-02 at 8 24 11 PM

If I click on any of the pages/tabs, the URL adds "PATH_PREFIX" after the domain (see screenshot). Pages load, but I don't think this is the indented behavior.
Screenshot 2025-01-02 at 8 24 50 PM

Also happens connecting directly to the web interface (not thorugh reverse proxy).
Screenshot 2025-01-02 at 8 30 12 PM
Screenshot 2025-01-02 at 8 30 18 PM

To Reproduce
Steps to reproduce the behavior:

  1. Go to root page.
  2. See 404 error
  3. Click on any tab on the left
  4. Page loads and URL shows PATH PREFIX

Expected behavior
URL path should not have PATH PREFIX in it. Should just load the root domain.

Screenshots
See above.
Screenshot 2025-01-02 at 8 59 26 PM

Device (please complete the following information):

  • OS: Ubuntu running docker container
  • Version 2.6.0

Additional context
Add any other context about the problem here. Recently updated to latest version.

@benscobie
Copy link
Collaborator

benscobie commented Jan 3, 2025

__PATH_PREFIX__ is supposed to be replaced on startup.

Could you share your docker run / compose? Are there any errors in your Docker logs on startup?

Your screenshot is showing a really old GIT_SHA (Feb 11, 2024), are these the latest env vars? EDIT: Ah, this is likely the cause of that: portainer/portainer#8835 - Could you try re-creating the container from scratch using your existing volume and see if the problem still exists?

@zhazell
Copy link
Author

zhazell commented Jan 3, 2025

The entrypoint on the container had something weird. When recreating the container it defaulted back to
'/opt/app/start.sh'
And now it's working properly. Must have been something that stuck around from an older image version.

@zhazell zhazell closed this as completed Jan 3, 2025
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

No branches or pull requests

2 participants