{"repo":"BretFisher/nodejs-rocks-in-docker","free":true,"listed":false,"github":"https://github.com/BretFisher/nodejs-rocks-in-docker","clone":"git clone https://github.com/BretFisher/nodejs-rocks-in-docker.git","description":"DockerCon \"Docker for Node.js\" examples","language":"Dockerfile","stars":515,"topics":["docker","dockercon","nodejs","containers","node","node-module","dockerfile","docker-compose"],"license":"MIT","category":"deployment-docker-iac","readme_excerpt":"Node.js Rocks in Docker My DockerCon 2023 talk, which is an update of my DockerCon 2022 talk, which is an update of my DockerCon 2019 talk \"Node.js Rocks in Docker and DevOps\" - DockerCon 2023 talk on YouTube - DockerCon 2022 talk on YouTube - DockerCon 2019 talk on YouTube Want more? Get my Docker Mastery for Node.js course with a coupon: 9 hours of video to help a Node.js developer use all the best Docker features. Also, here's my other example repositories including DevOps automation, Docker, and Kubernetes stuff. Who is this for? - You know some Node.js - You know some Docker - You want more Node+Docker awesomesauce Table of Contents - Searching for the best Node.js base image - TL;DR - General goals of a Node.js image - Node.js base image comparison stats, September 25th, 2023 - My recommended (v18) - Comparison highlights - Ruling out Alpine - Ruling out node:latest or node:lts - Ruling out debian: -slim as a custom base - Building a custom Node.js image based on Ubuntu - Ruling out NodeSource deb packages - 👉 My favorite custom Node.js base image - Using distroless - The better distroless setup? - Dockerfile best practices for Node.js - You've got a .dockerignore right? - Use npm ci --only=production first, then layer dev/test on top - Change user to USER node - Proper Node.js startup: tini - Avoid node process managers (npm, yarn, nodemon, forever, pm2) - Add Multi-Stage For a Single Dev-Test-Prod Dockerfile - Adding test, lint, and auditing stages - Add multi-archit","default_branch":null,"files":null,"tree":[],"storefront":"/r/BretFisher","claimed":false,"request_supported":{"post":"https://gitbuyer.com/r/BretFisher/nodejs-rocks-in-docker/request-supported","requests":0},"note":"indexed from public GitHub; nothing is for sale on this page. Clone it from GitHub. Paid listings live at /search."}