title: env_file is ignored in docker-compose and cause "The ... variable is not set" warning
body: <p>I simply want to use a environment variable loaded from file in my docker-compose file. But after running the container, I only got </p>
  
  <blockquote>
    <p>WARNING: The TESTVAR variable is not set. Defaulting to a blank string.</p>
  </blockquote>
  
  <p>Only found <a href="https://stackoverflow.com/questions/37982317/docker-compose-doesnt-recognize-env-file">this topic</a>, but I'm using a later version of docker like there (docker-compose: <code>1.14.0</code>, docker: <code>17.05.0-ce</code>). And I changed the encoding to <code>ISO 8859-1</code>, since I found a github issue where strange behavior with encodings was detected. Both doesn't work. </p>
  
  <p>My docker-compose file</p>
  
  <pre><code>version: '2'
  services:
    mysql:
      container_name: test_${TESTVAR}
      build: mysql
      mem_limit: 1G
      env_file:
        - credentials.env
  </code></pre>
  
  <p>credentials.env contains only <code>TESTVAR=test123</code>. To start, I run <code>docker-compose up mysql</code> and I also tried to specify the environment variables directly in the compose file like this: </p>
  
  <pre><code>environment:
    - TESTVAR=1234
  </code></pre>
  
  <p>Not working, too. </p>