<p>I am building the Dockerfile for python script which will run in minikube windows 10 system below is my Dockerfile</p>

<p>Building the docker using the below command
<code>docker build -t python-helloworld .</code></p>

<p>and loading that in minikube docker demon
<code>docker save python-helloworld | (eval $(minikube docker-env) &amp;&amp; docker load)</code></p>

<p>Docker File</p>

<pre><code>FROM python:3.7-alpine
#add user group and ass user to that group
RUN addgroup -S appgroup &amp;&amp; adduser -S appuser -G appgroup

#creates work dir   
WORKDIR /app

#copy python script to the container folder app
COPY helloworld.py /app/helloworld.py

#user is appuser
USER appuser

ENTRYPOINT  ["python", "/app/helloworld.py"]
</code></pre>

<p>pythoncronjob.yml file (cron job file)</p>

<pre><code>apiVersion: batch/v1beta1
kind: CronJob
metadata:
  name: python-helloworld
spec:
  schedule: "*/1 * * * *"
  jobTemplate:
    spec:
      backoffLimit: 5
      template:
        spec:
          containers:
          - name: python-helloworld
            image: python-helloworld
            imagePullPolicy: IfNotPresent
            command: [/app/helloworld.py]
          restartPolicy: OnFailure
</code></pre>

<p>Below is the command to run this Kubernetes job
<code>kubectl create -f pythoncronjob.yml</code></p>

<p>But getting the below  error job is not running scuessfully but when u ran the Dockerfile alone its work fine </p>

<p>standard_init_linux.go:211: exec user process caused "exec format error"</p>

<p>This can also happen when your host machine has a different architecture from your guest container image.</p>
<p>E.g. running an arm container on a host with x86-64 architecture</p>
