title: Ansible docker_container 'no Host in request URL', docker pull works correctly
body: <p>I'm trying to provision my infrastructure on AWS using Ansible playbooks. I have the instance, and am able to provision docker-engine, docker-py, etc. and, I swear, yesterday this worked correctly and I haven't changed the code since. </p>
  
  <p>The relevant portion of my playbook is: </p>
  
  <pre><code>- name: Ensure AWS CLI is available
    pip:
      name: awscli
      state: present
    when: aws_deploy
  - block:
    - name: Add .boto file with AWS credentials.
      copy:
        content: "{{ boto_file }}"
        dest: ~/.boto
      when: aws_deploy
    - name: Log in to docker registry.
      shell: "$(aws ecr get-login --region us-east-1)"
      when: aws_deploy
    - name: Remove .boto file with AWS credentials.
      file:
        path: ~/.boto
        state: absent
      when: aws_deploy
    - name: Create docker network
      docker_network:
        name: my-net
    - name: Start Container
      docker_container:
        name: example
        image: "{{ docker_registry }}/example"
        pull: true
        restart: true
        network_mode: host
        volumes:
          - /etc/localtime:/etc/localtime:ro
          - /etc/timezone:/etc/timezone
  </code></pre>
  
  <p>My <code>{{ docker_registry }}</code> is set to <code>my-acct-id.dkr.ecr.us-east-1.amazonaws.com</code> and the result I'm getting is:</p>
  
  <pre><code>"msg": "Error pulling my-acct-id.dkr.ecr.us-east-1.amazonaws.com/example - code: None message: Get http://: http: no Host in request URL"
  </code></pre>
  
  <p>However, as mentioned, this worked correctly last night. Since then I've made some VPC/subnet changes, but I'm able to ssh to the instance, and run <code>docker pull my-acct-id.dkr.ecr.us-east-1.amazonaws.com/example</code> with no issues.</p>
  
  <p>Googling has led me not very far as I can't seem to find other folks with the same error. I'm wondering what changed, and how I can fix it! Thanks!</p>
  
  <p>EDIT: Versions:</p>
  
  <ul>
  <li>ansible - 2.2.0.0 </li>
  <li>docker - 1.12.3 6b644ec </li>
  <li>docker-py - 1.10.6</li>
  </ul>