gis-ops / docker-valhalla

This is our flexible Docker repository for the Valhalla routing engine
MIT License
233 stars 69 forks source link

consider simplifying Dockerfile #50

Closed markstos closed 1 year ago

markstos commented 2 years ago

Currently this Dockerfile pulls a few files from the valhalla/valhalla Docker image, deletes the rest and starts from scratch with a Ubuntu 20.04 base.

But the valhalla/valhalla image itself is built on a Ubuntu 20.04 base, and this image is re-installing at least the following packages which are already present in the valhalla/valhalla image:

curl
jq
libluajit-5.1-2 
libsqlite3-mod-spatialite 
parallel 
spatialite-bin 
unzip 

It would seem to simplify the system overall if this Docker image was simply based directly on the valhalla/valhalla image, and then only added the additional dependencies it needs.

nilsnolde commented 2 years ago

that's actually very much on purpose. the valhalla image is huge, it has the (gzipped but still) entire debug symbol stuff. honestly I'm not sure anymore if deleting stuff from a base image really drives down the final image size much with docker's layering scheme, but also I wouldn't prefer that. I rather pull in from the valhalla/valhalla base image what I need in a multi-stage process. much cleaner IMHO.

I agree that curl can go though, true.