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

maptiler-server & nginx proxy to a URL with sub-folder #1103

Open
wxrl opened this issue Dec 26, 2023 · 4 comments
Open

maptiler-server & nginx proxy to a URL with sub-folder #1103

wxrl opened this issue Dec 26, 2023 · 4 comments

Comments

@wxrl
Copy link

wxrl commented Dec 26, 2023

OS: Debian 12 with nginx 1.22.1
Maptiler: maptiler-server 4.4.0 directly installed with .deb package

After installation I can proxy http://127.0.0.1:3650 to http:// or https://xxx.mydomain.com but kept failing to proxy it to https://xxx.mydomain.com/map

There are some parameters I found here baseurl and public_url, neither of them worked no matter I used them in the maptiler-server execution command or in the config.json. Could anyone suggest? Thanks.

@wxrl wxrl changed the title maptiler-server & nginx proxy to a sub-folder maptiler-server & nginx proxy to a URL with sub-folder Dec 26, 2023
@acalcutt
Copy link
Collaborator

Maptiler-server is a different product by maptiler. This is tileserver-gl, a open source tileserver.

For tileserver-gl you should be following the documentation at https://maptiler-tileserver.readthedocs.io/ . For one, the default port tileserver-gl runs on is 8080, not 3650

@vasily-polonsky
Copy link

Hi @acalcutt
I am facing the same issue while working with tileserver-gl-light. I tried options from the help command (-u|--public_url to enable exposing the server on subpaths, not necessarily at the domain's root). However, they haven't worked for me. I've also tried different variations from the documentation at https://maptiler-tileserver.readthedocs.io/, but with no luck. Is there an example available on how to run it not on the root directory?

@wxrl
Copy link
Author

wxrl commented Dec 27, 2023

Maptiler-server is a different product by maptiler. This is tileserver-gl, a open source tileserver.

For tileserver-gl you should be following the documentation at https://maptiler-tileserver.readthedocs.io/ . For one, the default port tileserver-gl runs on is 8080, not 3650

Sorry for the wrong place... I couldn't find the maptiler-server repo under maptiler github, so I thought there might be someone who could help here. Again sorry for the intruding.

@RadekDvorak
Copy link

What I do to inject a path prefix into tileserver-gl is append it to the Host header. It is not validated in any way. The header is manipulated by an nginx proxy on the way to the tileserver-gl.

There has been a X-Forwarded-Path header support added in v4.11.0 which I am yet to investigate as a proper replacement.

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

No branches or pull requests

4 participants