npm ERR! path /app/node_modules/npm/node_modules/ansistyles npm ERR! code ENOENT npm ERR! errno -2 npm ERR! syscall rename npm ERR! enoent ENOENT: no such file or directory, rename '/app/node_modules/npm/node_modules/ansistyles' -> '/app/node_modules/npm/node_modules/.ansistyles.DELETE' npm ERR! enoent This is related to npm not being able to find a file. npm ERR! enoent npm ERR! A complete log of this run can be found in: npm ERR! /root/.npm/_logs/2018-08-29T08_17_27_580Z-debug.log
Offer your help. Be nice!
This issue could have many causes based on my research.
For me, it was copying my
/app/node_modules directory from my host into the Docker image.
I solved it by adding
/shop/node_modules to my
.dockerignore and building again with