librephotos-docker
librephotos-docker copied to clipboard
Use multi stage docker build
Suggestion: Use multi stage docker build to only copy data model files instead of also including the whole tar file. Multi stage build will also mean that only the dlib binaries are packaged; the dlib source and dlib object files won't be part of the build. Preliminary testing on my system shows an image reduction about ~1GB on the backend device. If any other deadweight from the build process can also be shed, it can make the image much leaner and easier to run on lower end devices.
I would submit a pull request but I'm not certain how the dlib binaries are installed/referred, so just a direct change to the dockerfile may cause regressions.
How about you open up a pull request with your current changes and push an image to docker hub. I would try to find some people who use CPUs that don't support AVX, to install and test it.
Created PR #17