title: Airflow BashOperator: Passing parameter to external bash script
body: <p>Having problems passing parameters to an external bash script from a BashOperator.
  When I run a local command, the params are substituted correctly:</p>
  
  <pre><code>log_cleanup = """ echo "{{ params.BASE_LOG_FOLDER }}" """
  log_cleanup_task = BashOperator(
          task_id='log_cleanup_task',
          provide_context=True,
          bash_command = log_cleanup,
          params = {'BASE_LOG_FOLDER': "/var/opt"},
          dag=dagInstance,
  )
  
  prints:  "/var/opt"   (without the double quotes)
  </code></pre>
  
  <p>But if I call an external bash script, the params don't substitute in.</p>
  
  <pre><code>log_cleanup_task = BashOperator(
          task_id='log_cleanup_task',
          provide_context=True,
          bash_command= str(DAGS_FOLDER)+"/scripts/log_cleanup.sh ",
          params = {'BASE_LOG_FOLDER': "/var/opt" },
          dag=dagInstance,
  )
  
  #log_cleanup.sh:
  #! /usr/bin/bash
  echo "{{ params.BASE_LOG_FOLDER }}"
  
  
  prints: "{{ params.BASE_LOG_FOLDER }}"    (without the double quotes)
  </code></pre>
  
  <p>In the external bash script, I can't get the parameters to substitute in like they do when the statement is stored within the DAG .py script.</p>
  
  <p>Do I have to pass the params as command line arguments instead? Does the jinja templating only works in the .py files? </p>