maps-docker-compose icon indicating copy to clipboard operation
maps-docker-compose copied to clipboard

Import custom PBF file

Open zubair1024 opened this issue 2 years ago • 1 comments

Hi, is there a possibility to import a custom PBF file instead of using online mirrors?

zubair1024 avatar Apr 13 '22 09:04 zubair1024

I'm fairly certain if you wanted to do it properly you would have to modify renderd-docker etc...

A fairly quick workaround (without updates tho) is just launching a local fileserver with your custom PBF. For example: http-server -p 12345

Then you need to add localhost access to your renderd- and Postgres-Containers:

extra_hosts:
      - "host.docker.internal:host-gateway"

You also need to calculate a new md5-Checksum: md5sum custom.osm.pbf > custom.osm.pbf.md5

Then you can just access your local file like this and leave update empty (its necessary to have it in an additional folder like /mapfiles here)

OSM_PBF_URL=host.docker.internal:12345/mapfiles/custom.osm.pbf
OSM_PBF_UPDATE_URL=

kwikma avatar Jun 02 '22 09:06 kwikma