You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

21 lines
740 B

  1. ---
  2. - name: create docker service directory for RHEL family
  3. file: path=/etc/systemd/system/docker.service.d state=directory
  4. when: ansible_distribution in ["CentOS","RedHat"] and
  5. ansible_distribution_major_version >= 7
  6. - name: drop docker environment for RHEL family
  7. template:
  8. src: http-proxy.conf.j2
  9. dest: /etc/systemd/system/docker.service.d/http-proxy.conf
  10. when: ansible_distribution in ["CentOS","RedHat"] and
  11. ansible_distribution_major_version >= 7
  12. register: rheldockerproxy
  13. - name: reload systemctl daemons for RHEL family
  14. shell: systemctl daemon-reload
  15. when: rheldockerproxy.changed
  16. - name: restart docker for RHEL family
  17. service: name=docker state=restarted
  18. when: rheldockerproxy.changed