- name: Create docker directory become: yes file: state: directory path: /etc/docker - name: Install docker-ce from upstream include: upstream.yaml when: use_upstream_docker|bool - name: Install docker-engine from distro include: distro.yaml when: not use_upstream_docker|bool - name: reset ssh connection to pick up docker group meta: reset_connection # We install docker-compose from pypi to get features like # stop_grace_period. - name: ensure pip3 is installed include_role: name: pip3 - name: Install docker-compose pip: name: docker-compose state: present executable: pip3