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.

43 lines
1.0 KiB

9 years ago
  1. ---
  2. - name: Flannel | delete default docker bridge
  3. command: ip link delete docker0
  4. failed_when: false
  5. notify: Flannel | restart docker
  6. - name: Flannel | restart docker
  7. command: /bin/true
  8. notify:
  9. - Flannel | reload systemd
  10. - Flannel | reload docker.socket
  11. - Flannel | reload docker
  12. - Flannel | pause while Docker restarts
  13. - Flannel | wait for docker
  14. - name : Flannel | reload systemd
  15. shell: systemctl daemon-reload
  16. - name: Flannel | reload docker.socket
  17. service:
  18. name: docker.socket
  19. state: restarted
  20. when: ansible_os_family in ['CoreOS', 'Container Linux by CoreOS']
  21. - name: Flannel | reload docker
  22. service:
  23. name: docker
  24. state: restarted
  25. - name: Flannel | pause while Docker restarts
  26. pause: seconds=10 prompt="Waiting for docker restart"
  27. - name: Flannel | wait for docker
  28. command: "{{ docker_bin_dir }}/docker images"
  29. register: docker_ready
  30. retries: 10
  31. delay: 5
  32. until: docker_ready.rc == 0
  33. - name: Flannel | reload kubelet
  34. service:
  35. name: kubelet
  36. state: restarted