𝗗𝗲𝗽𝗹𝗼𝘆 𝗟𝗮𝗿𝗮𝘃𝗲𝗹 𝗪𝗶𝘁𝗵 𝗗𝗼𝗰𝗸𝗲𝗿 𝗔𝗻𝗱 𝗞𝘂𝗯𝗲𝗿𝗻𝗲𝘁𝗲𝘀

Your Docker images should be small. Large images slow down your deployment.

Use multi-stage builds to fix this.

Stage one is the builder.

Stage two is production.

You need three more things for a professional setup:

  1. Nginx configuration.
  1. PHP optimization.
  1. Supervisord.

This setup works well for Kubernetes. It is fast and secure.

Source: https://dev.to/akandwanaho_alvin_5726f54/deploying-laravel-with-docker-github-actions-and-kubernetes-561i