Docker and CI/CD · Junior · Question 61 of 75
Why pin FROM node:22.11-slim instead of FROM node?
- ✓Correct answer: So builds don't silently change when the base updates
- 2So that Docker can skip downloading the base image
- 3Because untagged images can't be pulled from Docker Hub
Explanation
node means node:latest, which jumps major versions over time. A pinned tag (or even a digest) keeps builds reproducible; update it deliberately.