← Learn
Safe
docker run --rm -v "$PWD":/work:ro -w /work node:20-alpine npm run lint

cross-platform · dockerfile · Nightmare

Lints the current project inside a throwaway container. Mounting your working directory into a container deserves scrutiny, but :ro makes the mount read-only and --rm deletes the container afterwards, so nothing can be written back or left behind.

Think you can spot these under time pressure?

Start Training

More Containers