title: How to pass command line arguments to my dockerized python app
body: <p>I have a simple docker file which I am using to containerize my python app. The app actually takes file paths as command line arguments. It is my first time using Docker and I am wondering how I can achieve this:</p>
  
  <pre><code>FROM python:3.6-slim
  
  COPY . /app
  WORKDIR /app
  
  RUN apt-get update &amp;&amp; apt-get -y install gcc g++
  # Install numpy, pandas, scipy and scikit
  RUN pip install --upgrade pip
  
  RUN pip --no-cache-dir install -r requirements.txt
  RUN python setup.py install
  
  ENTRYPOINT python -m myapp.testapp
  </code></pre>
  
  <p>Please note that the python app is run from the from the module with the <code>-m</code> flag.</p>
  
  <p>This builds the image completely fine. I can also run it using:</p>
  
  <pre><code>docker run -ti myimg
  </code></pre>
  
  <p>However, I cannot pass any command line arguments to it. For example, my app prints some help options with the -h option.</p>
  
  <p>However, running docker as:</p>
  
  <pre><code>docker run -ti myimg -h
  </code></pre>
  
  <p>does not do anything. So, the command line option are not being passed.</p>
  
  <p>Additionally, I was wondering what the best way to actually pass file handles from the host computer to docker. So, for example, the application takes path to a file as an input and the file would usually reside on the host computer. Is there a way for my containerized app to be able to access that?</p>