<p>I am trying to create a pod based on a container image from local machine not from public registry. I am retrieving the status of pod as ImagePullBackoff
Docker file</p>
<pre><code>FROM tensorflow/tensorflow:latest-py3
RUN pip install -q keras==2.3.1
RUN pip install pillow
RUN mkdir -p /app/src
WORKDIR /app/src
COPY . ./
EXPOSE 31700
CMD [&quot;python&quot;, &quot;test.py&quot;]
</code></pre>
<p>To build the docker image</p>
<pre><code>docker build -t tensor-keras .
</code></pre>
<p>To create a pod without using yaml file</p>
<pre><code>kubectl run server --image=tensor-keras:latest
</code></pre>
<p>Yaml file</p>
<pre><code>apiVersion: v1 
kind: Pod
metadata:
 name: server
 labels: 
    app: server
spec:
 containers:
  - name:  tensor-keras
    image: tensor-keras:latest
    ports:
    - containerPort: 31700
</code></pre>
<p>I am retreiving the status of the pod as</p>
<pre><code>  NAME          READY   STATUS             RESTARTS   AGE
  server         0/1   ImagePullBackOff      0        27m        

  
</code></pre>
<p>Help is highly appreciated thanks</p>

<p>By default, Kubernetes will try to pull your image from a remote container repository. In your case, your image name is not prefixed by a container repository url, so it uses default one, most of the time it is set to Docker Hub.</p>
<p>What is the value of the  <code>imagePullPolicy</code> field? For you use-case it should be set to <code>Never</code> to use local image.
Which tool are you using to run your Kubernetes instance?</p>
<ul>
<li>For example, with minikube, procedure to use a local image is described here: <a href="https://stackoverflow.com/a/42564211/2784039">https://stackoverflow.com/a/42564211/2784039</a></li>
<li>With kind, you should use command <code>kind load docker-image &lt;tensor-keras:latest&gt;</code> o load the image inside your cluser</li>
<li>With k3s, using local image should work out of the box, if <code>imagePullPolicy</code> is set to  <code>Never</code></li>
</ul>
