DEV Community

Discussion on: Top 5 Docker Best Practices

Collapse
 
localpath profile image
Garrick Crouch

Good ideas I would point out avoid chown as a layer since it can take a really long time to run recursively.

The COPY --chown=node:node . /app command has a chown flag built in for that very purpose that is performant

Collapse
 
karanpratapsingh profile image
Karan Pratap Singh

Great tip! Thank you 😊