<p>Using <code>microk8s</code> installation. An image is tagged, so should use <code>IfNotPresent</code> policy.</p>
<pre><code>apiVersion: apps/v1
  2 kind: Deployment
  3 metadata:
  4   name: lh-graphql
  5   labels:
  6     app: lh-graphql 
  7 spec:
  8   selector:
  9     matchLabels:
 10       app: lh-graphql
 11   strategy:
 12     type: Recreate
 13   template:
 14     metadata:
 15       labels:
 16         app: lh-graphql
 17     spec:
 18       containers:
 19       - image: hasura/graphql-engine:v2.13.2.cli-migrations-v3 
 20         name: lh-graphql 
 21         ports:
 22         - containerPort: 8080
 23           name: lh-graphql        
 24         env:
 25         - name: HASURA_GRAPHQL_DATABASE_URL  
 26           value: postgresql://postgres:postgres@$(ORCH_POSTGRES_IP):5432/lh
</code></pre>
<p>Image is already pulled to docker:</p>
<pre><code>light@siddhalok:~$ docker image ls
REPOSITORY                                                   TAG                         IMAGE ID       CREATED        SIZE
postgres                                                     12                          3d6880d04326   2 weeks ago    373MB
hasura/graphql-engine                                        v2.13.2.cli-migrations-v3   4cd490369623   2 months ago   570MB
</code></pre>
<p>However, it keeps pulling after a deployment is deleted and created again.</p>
<pre><code>Events:
  Type    Reason     Age   From               Message
  ----    ------     ----  ----               -------
  Normal  Scheduled  112s  default-scheduler  Successfully assigned default/lh-graphql-6db75544cf-j65wp to siddhalok
  Normal  Pulling    112s  kubelet            Pulling image &quot;hasura/graphql-engine:v2.13.2.cli-migrations-v3&quot;

</code></pre>
<p><strong>UPD:</strong></p>
<p>The same happens when creating from command line:</p>
<pre><code>microk8s kubectl run det2 --image=registry.dev.mpksoft.ru/lighthouse/lh-detector/lh-detector:current --image-pull-policy=IfNotPresent
</code></pre>
<pre><code>REPOSITORY                                                   TAG                         IMAGE ID       CREATED        SIZE
postgres                                                     12                          3d6880d04326   2 weeks ago    373MB
lh-develop.img                                               latest                      f26c3c667fbe   5 weeks ago    2.82GB
dpage/pgadmin4                                               latest                      4d5afde0a02e   6 weeks ago    361MB
detector                                                     latest                      e6f7e6567b73   7 weeks ago    3.81GB
lh-detetctor.img                                             latest                      e6f7e6567b73   7 weeks ago    3.81GB
registry.dev.mpksoft.ru/lighthouse/lh-detector/lh-detector   current                     e6f7e6567b73   7 weeks ago    3.81GB
</code></pre>

noname7619
<p>If you are running the <strong>microK8s</strong> and Docker still it's necessary <strong>microk8s</strong> to have an idea about the docker that is running on your machine. local Docker daemon is not part of the <strong>MicroK8s</strong> Kubernetes cluster.</p>
<p>You can <strong>export</strong> the image and inject to <strong>cache</strong></p>
<pre><code>docker save &lt;image name&gt; &gt; myimage.tar
microk8s ctr image import myimage.tar
</code></pre>
<p>Ref : <a href="https://microk8s.io/docs/registry-images" rel="nofollow noreferrer">doc</a></p>
