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.

39 lines
907 B

  1. ---
  2. - hosts: localhost
  3. become: no
  4. tasks:
  5. - name: "Check ansible version >=2.7.8"
  6. assert:
  7. msg: "Ansible must be v2.7.8 or higher"
  8. that:
  9. - ansible_version.string is version("2.7.8", ">=")
  10. tags:
  11. - check
  12. vars:
  13. ansible_connection: local
  14. - hosts: bastion[0]
  15. gather_facts: False
  16. roles:
  17. - { role: kubespray-defaults}
  18. - { role: bastion-ssh-config, tags: ["localhost", "bastion"]}
  19. - hosts: all
  20. gather_facts: true
  21. - hosts: etcd:k8s-cluster:calico-rr
  22. vars_prompt:
  23. name: "reset_confirmation"
  24. prompt: "Are you sure you want to reset cluster state? Type 'yes' to reset your cluster."
  25. default: "no"
  26. private: no
  27. pre_tasks:
  28. - name: check confirmation
  29. fail:
  30. msg: "Reset confirmation failed"
  31. when: reset_confirmation != "yes"
  32. roles:
  33. - { role: kubespray-defaults}
  34. - { role: reset, tags: reset }