title: docker-entrypoint.sh : Only exec "$@" not working
body: <p>I was struggling to fix this issue from couple of days. </p>
  
  <p>File 1 : docker-entrypoint.sh</p>
  
  <pre><code>#!/bin/bash
  set -e
  source /home/${HADOOP_INSTALL_USERNAME}/.bashrc
  kinit -kt /home/${HADOOP_INSTALL_USERNAME}/keytab/dept-test-hadoop.${HADOOP_INSTALL_ENV}.keytab dept-test-hadoop
  mkdir /tmp/test222222
  exec "$@"
  </code></pre>
  
  <p>Dockerfile : </p>
  
  <pre><code>ENTRYPOINT ["/home/dept-test-hadoop/docker-entrypoint.sh"]
  </code></pre>
  
  <p>docker run command : </p>
  
  <pre><code>docker run -it hadoop-hive:v1 /bin/mkdir /tmp/test1
  </code></pre>
  
  <p>The challenge or what I am trying is to execute what ever the command that pass as command-line argument to docker run command.Please note these commands required kerberos authentication</p>
  
  <p>1) I have noticed <code>/tmp/test222222</code> but I could not see a directly like <code>/tmp/test1</code> with above docker run command. I think my exec <code>"$@"</code> in docker-entrypoint.sh not executing. But I can confirm the script is executing as I can see the <code>/tmp/test222222</code></p>
  
  <p>2) Is there way that we can assign the values from environment variables ? </p>
  
  <p><code>ENTRYPOINT ["/home/dept-test-hadoop/docker-entrypoint.sh"]</code></p>