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

Failing to download tiles from OpenTopoMap #1

Open
mogensen opened this issue Oct 26, 2018 · 1 comment
Open

Failing to download tiles from OpenTopoMap #1

mogensen opened this issue Oct 26, 2018 · 1 comment

Comments

@mogensen
Copy link

Hi,

First of, great project! Very easy to use and awesome with the docker container!

I am trying to generate a mbtiles file for opentopomap for using when hiking.
I beleve that the following command should work for this:

docker run -d -p 2999:2999 -e "APP_MODE=server" -e "TILESERVER_TYPE=osm" -e "TILESERVER_ENDPOINT=https://b.tile.opentopomap.org/{z}/{x}/{y}.png" -e "APP_TIMEOUT=300" -e "APP_MINZOOM=3" -e "APP_MAXZOOM=17" -e "APP_MAXAREA=16" mapsquare/mbtiles-generator-server

But what ever I do to try to generate the mbtiles files, they always end up being only 3kb, with no images in.

I think that the problem lies in that the opentopomap server demands https and not http as all the others servers I have used, that works.

I know that this is a fairly old project, but I would love to ba able to use it to create maps for hiking.

Thanks
Frederik Mogensen

@maratismailov
Copy link

That is because the app uses http.get method in app/service/mbtiles-generator-service.js. Import https instead of http and use https.get(). Keep in mind that this can lead to violation of OSM usage policy (https://operations.osmfoundation.org/policies/tiles/) "Bulk downloading is strongly discouraged. Do not download tiles unnecessarily. In particular, downloading an area of over 250 tiles at zoom level 13 or higher for offline or later usage is forbidden". Nevertheless you can use alternative tiles provider or host your own.

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