<p>I have an entrypoint defines as <code>ENTRYPOINT ["/bin/sh"]</code> in <code>Dockerfile</code>. The docker image contains most of the shell scripts. But later on I added a Golan scripts, which I want to run from kubernetes job. But due to entrypoint defined as <code>/bin/sh</code>, it gives me error <code>No such file or directory</code> when I try to run the compiled and installed go binary through <code>args</code> in yml of kubernetes job's deployment descriptor. </p>

<p>Any well defined way to achieve such goal?</p>

hemu
<p>As standing in <a href="https://kubernetes.io/docs/tasks/inject-data-application/define-command-argument-container/#notes" rel="nofollow noreferrer">documentation</a> you can override docker's entrypoint by using <code>command</code> section of pod's definition in deployment.yaml, example from docs:</p>

<pre><code>apiVersion: v1
kind: Pod
metadata:
  name: command-demo
  labels:
    purpose: demonstrate-command
spec:
  containers:
  - name: command-demo-container
    image: debian
    command: ["printenv"]
    args: ["HOSTNAME", "KUBERNETES_PORT"]
  restartPolicy: OnFailure
</code></pre>
