title: Docker stuck at npm install
body: <p>I have a project that I want to dockerize. I run <code>npm install</code> and <code>npm build</code> with no problem on my computer, but it has some problems when I build with Docker.</p>
  
  <p>Docker output:</p>
  
  <pre><code>Sending build context to Docker daemon  56.96MB
  Step 1/7 : FROM node:12.2.0-alpine
  ---&gt; f391dabf9dce
  Step 2/7 : WORKDIR /app
  ---&gt; Using cache
  ---&gt; b50a8efbf074
  Step 3/7 : ENV PATH /app/node_modules/.bin:$PATH
  ---&gt; Using cache
  ---&gt; 3358967a13ab
  Step 4/7 : COPY package.json /app/package.json
  ---&gt; Using cache
  ---&gt; 851ac31a0adb
  Step 5/7 : RUN npm install
  ---&gt; Running in 8cc36a435cec
  npm WARN deprecated core-js@1.2.7: core-js@&lt;2.6.8 is no longer maintained. Please, upgrade to core-js@3 or at least to actual version of core-js@2.
  </code></pre>
  
  <p>It is stuck in this here:</p>
  
  <p>Dockerfile:</p>
  
  <pre><code># base image
  FROM node:12.2.0-alpine
  
  # set working directory
  WORKDIR /app
  
  # add `/app/node_modules/.bin` to $PATH
  ENV PATH /app/node_modules/.bin:$PATH
  
  # install and cache app dependencies
  COPY package.json /app/package.json
  RUN npm install
  RUN npm install react-scripts@3.0.1 -g --silent
  
  # start app
  CMD ["npm", "start"]
  </code></pre>
  
  <p>I have done this with other dockerfiles, but the result was the same. </p>
  
  <p>package.json:</p>
  
  <pre><code>{
    "name": "front",
    "version": "0.1.0",
    "private": true,
    "dependencies": {
      "axios": "^0.18.0",
      "bootstrap": "^4.3.1",
      "express": "^4.17.0",
      "react": "^16.8.6",
      "react-dom": "^16.8.6",
      "react-router": "^5.0.0",
      "react-router-dom": "^5.0.0",
      "react-scripts": "2.1.8"
    },
    "scripts": {
      "start": "react-scripts start",
      "build": "react-scripts build",
      "test": "react-scripts test",
      "eject": "react-scripts eject"
    },
    "eslintConfig": {
      "extends": "react-app"
    },
    "browserslist": [
      "&gt;0.2%",
      "not dead",
      "not ie &lt;= 11",
      "not op_mini all"
    ]
  }
  </code></pre>