diff --git a/roles/docker/tasks/main.yml b/roles/docker/tasks/main.yml index 2b5c24f5e..3668f61b8 100644 --- a/roles/docker/tasks/main.yml +++ b/roles/docker/tasks/main.yml @@ -118,6 +118,12 @@ notify: restart docker when: not (ansible_os_family in ["CoreOS", "Container Linux by CoreOS"] or is_atomic) and (docker_package_info.pkgs|length > 0) +- name: ensure service is started if docker packages are already present + service: + name: docker + state: started + when: docker_task_result is not changed + - name: flush handlers so we can wait for docker to come up meta: flush_handlers