Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat(Dockerfile): Use multistage build to skip libpostal build depend…
…encies After pelias/docker-baseimage#23, we will no longer have a compiler toolchain in our Docker baseimage. However, due to the way Docker images work and build upon each other, the biggest wins come from ensuring we don't have a compiler toolchain _anywhere_ in our images. If you think about it, even a single image having a compiler toolchain is the same as the baseimage having it, at least when comparing the total size of all our images. Thankfully, with multistage builds we can easily remove both the C++ compiler toolchain and Golang buildtime dependencies in the libpostal service, similar to pelias/polylines#263. This alone drops the total image size for the libpostal-service from 3.2GB to 2.8GB. Further improvements are possible in the libpostal baseimage.
- Loading branch information