docker: various improvements to Dockerfile
This includes the following changes: - Use multi-stage build to run application in an optimized environment, see https://docs.docker.com/develop/develop-images/multistage-build/ - Run application on alpine instead of archlinux to further reduce image size - Build Crystal application with --release for improved runtime performance - Run application as non-root user for better security, see https://docs.docker.com/develop/develop-images/dockerfile_best-practices/#user - Only rebuild Docker layers when requiredpull/665/head
parent
f99a7b2a8c
commit
ea39bb4334
Loading…
Reference in New Issue