Hacker News new | ask | show | jobs
by nhumrich 2632 days ago
The && is just layer squashing and not really needed. You can just use run on every line. Docker even supports squashing images now, so the && doesn't matter if you squash.
1 comments

&& doesn't layer squash, it's a trick to avoid the layer commit that RUN implies.

And squashing comes with a major drawback: you lose layer caching and any hope of a vaguely-efficient rebuilding process.