k8s_create.yaml 708 B

123456789101112131415161718192021222324252627282930
  1. ---
  2. # cybergavin
  3. # Create a Kubernetes cluster with a single-node control plane
  4. # Uses inventory details in files/inventory
  5. #
  6. - name: Prepare all nodes for the creation of the Kubernetes cluster
  7. hosts: all
  8. remote_user: auto.svc
  9. become: yes
  10. gather_facts: True
  11. tasks:
  12. - include: k8s_prep.yaml
  13. - name: Create the Kubernetes cluster
  14. hosts: control-plane
  15. remote_user: auto.svc
  16. become: yes
  17. gather_facts: True
  18. tasks:
  19. - include: k8s_cp_init.yaml
  20. - include: k8s_calico.yaml
  21. - include: k8s_joincommand.yaml
  22. - name: Join nodes to the Kubernetes cluster
  23. hosts: nodes
  24. remote_user: auto.svc
  25. become: yes
  26. gather_facts: True
  27. tasks:
  28. - include: k8s_join_node.yaml