<p>when I try to deploy application in Kubernetes using images in my private Docker registry on same server (master node), I receive following error:</p>

<blockquote>
  <p>Failed to pull image
  "0.0.0.0:5000/continuous-delivery-tutorial:5ec98331a69ec5e6f818583d4506d361ff4de89b-2020-02-12-14-37-03":
  rpc error: code = Unknown desc = Error response from daemon: Get
  <a href="https://0.0.0.0:5000/v2/" rel="nofollow noreferrer">https://0.0.0.0:5000/v2/</a>: http: server gave HTTP response to HTTPS
  client</p>
</blockquote>

<p>When I print <code>docker system info</code> I can see there is my registry as insecure registry:</p>

<p><a href="https://i.stack.imgur.com/y5bqe.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/y5bqe.png" alt="enter image description here"></a></p>

<p>I run my registry by following command:</p>

<pre><code>docker run -d -p 5000:5000 --restart=always --name registry -v $PWD/docker_reg_certs:/certs -e REGISTRY_HTTP_TLS_CERTIFICATE=/certs/domain.crt -e REGISTRY_HTTP_TLS_KEY=/certs/domain.key registry:2
</code></pre>

<p>Thank you for any advice</p>

<p>you need to add your hostname to the list of allowed insecure registries in <code>/etc/docker/daemon.json</code>, for example:</p>
<pre class="lang-json prettyprint-override"><code>{
  &quot;insecure-registries&quot; : [&quot;your-computer-hostname:5000&quot;]
}
</code></pre>
<p>(this file is supposed to contain 1 json object, so if it's not empty then add <code>insecure-registries</code> property to the existing object instead of creating a new one. Also remember to restart your docker daemon afterwards)<br/>
<br/>
also, you should not use <code>0.0.0.0</code> as it is not a real address. use your hostname instead when specifying image, like <code>your-computer-hostname:5000/continuous-delivery-tutorial:5ec98331a69ec5e6f818583d4506d361ff4de89b-2020-02-12-14-37-03</code></p>
