kubernetes.yml 1.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960
  1. # Copyright 2020 Dell Inc. or its subsidiaries. All Rights Reserved.
  2. #
  3. # Licensed under the Apache License, Version 2.0 (the "License");
  4. # you may not use this file except in compliance with the License.
  5. # You may obtain a copy of the License at
  6. #
  7. # http://www.apache.org/licenses/LICENSE-2.0
  8. #
  9. # Unless required by applicable law or agreed to in writing, software
  10. # distributed under the License is distributed on an "AS IS" BASIS,
  11. # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  12. # See the License for the specific language governing permissions and
  13. # limitations under the License.
  14. ---
  15. #Playbook for kubernetes cluster
  16. - name: Gather facts from all the nodes
  17. hosts: all
  18. - name: Apply common installation and config
  19. hosts: manager, compute
  20. gather_facts: false
  21. roles:
  22. - common
  23. - name: Apply GPU node config
  24. hosts: compute
  25. gather_facts: false
  26. roles:
  27. - compute_gpu
  28. - name: Apply manager config
  29. hosts: manager
  30. gather_facts: false
  31. roles:
  32. - manager
  33. - name: Apply firewalld config on manager and compute nodes
  34. hosts: manager, compute
  35. gather_facts: false
  36. roles:
  37. - firewalld
  38. - name: Start K8s on manager server
  39. hosts: manager
  40. gather_facts: false
  41. roles:
  42. - startmanager
  43. - name: Start K8s worker servers on compute nodes
  44. hosts: compute
  45. gather_facts: false
  46. roles:
  47. - startworkers
  48. - name: Start K8s worker servers on manager nodes
  49. hosts: manager
  50. gather_facts: false
  51. roles:
  52. - startservices