<p>I have a dockerfile finishing with an entrypoint:<br/></p>
<pre><code>ENTRYPOINT [&quot;/bin/bash&quot; , &quot;-c&quot;, &quot;source /app/env.sh &amp;&amp; printenv &amp;&amp; python3 /app/script.py&quot;]
</code></pre>
<p>And a yaml k8s CronJob:</p>
<pre><code>apiVersion: batch/v1beta1
kind: CronJob
metadata:
  name: my_healthcheck
  namespace: default
  labels:
    app: my_healthcheck
spec:
  schedule: &quot;30 8 * * 1-5&quot;
  jobTemplate:
    spec:
      backoffLimit: 5
      template:
        spec:
          containers:
            - name: pythonscript
              image: xxx/pythonscript:latest
          imagePullPolicy: IfNotPresent
          command: [ &lt;what do i put here&gt; ]
          restartPolicy: OnFailure
</code></pre>
<p>Inside &quot;command&quot;, what command i need to put, to run the container ?
thanks</p>

YoussHark
<p>The image <code>ENTRYPOINT</code> handles everything, so the <code>command</code> doesn't need to supplied.</p>
<p>If you do provide a <code>command</code>, it will override the <code>ENTRYPOINT</code>.</p>
<pre><code>    command: [ '/bin/bash', '-c', 'echo &quot;not running python&quot;' ]
</code></pre>
<p>You can supply <code>args</code> if you want to append arguments to the <code>command</code>/<code>ENTRYPOINT</code>.</p>
<p>See the <a href="https://stackoverflow.com/questions/44316361/difference-between-docker-entrypoint-and-kubernetes-container-spec-command">difference between the Kubernetes/Docker terms</a>.</p>
