title: unauthorized: authentication required error while creating docker nodejs image
body: <p>I am new to docker and trying to build docker image for my nodejs project.</p>
  <p>This is my docker file</p>
  <pre><code>FROM node:10
  WORKDIR /app
  COPY package*.json ./
  RUN npm install
  COPY . .
  EXPOSE 8443
  CMD [&quot;node&quot;, &quot;index.js&quot;]
  </code></pre>
  <p>Command used to build the image</p>
  <pre><code>docker build -r test-project .
  </code></pre>
  <p>It is giving <strong>unauthorized: authentication required</strong> after few minutes</p>
  <pre><code>Step 1/7 : FROM node:10
  10: Pulling from library/node
  76b8ef87096f: Extracting [====================&gt;                              ]  18.81MB/45.38MB
  2e2bafe8a0f4: Download complete
  b53ce1fd2746: Download complete
  84a8c1bd5887: Downloading [==============================&gt;                    ]  30.38MB/49.79MB
  7a803dc0b40f: Downloading [========&gt;                                          ]  34.34MB/214.3MB
  b800e94e7303: Downloading
  0da9fbf60d48: Waiting
  04dccde934cf: Waiting
  73269890f6fd: Waiting
  **unauthorized: authentication required**
  </code></pre>
  <p>I have done authentication before starting build using</p>
  <pre><code>docker login -u &lt;username&gt;
  </code></pre>
  <p>Please help with authentication error while building docker image.</p>