add_nodes.yml 1.5 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243
  1. ---
  2. - name: Launch instance(s)
  3. hosts: localhost
  4. connection: local
  5. become: no
  6. gather_facts: no
  7. vars_files:
  8. - vars.yml
  9. vars:
  10. oo_extend_env: True
  11. tasks:
  12. - fail:
  13. msg: Deployment type not supported for gce provider yet
  14. when: deployment_type == 'enterprise'
  15. - include: ../../common/openshift-cluster/tasks/set_node_launch_facts.yml
  16. vars:
  17. type: "compute"
  18. count: "{{ num_nodes }}"
  19. - include: tasks/launch_instances.yml
  20. vars:
  21. instances: "{{ node_names }}"
  22. cluster: "{{ cluster_id }}"
  23. type: "{{ k8s_type }}"
  24. g_sub_host_type: "{{ sub_host_type }}"
  25. gce_machine_type: "{{ lookup('env', 'gce_machine_node_type') | default(lookup('env', 'gce_machine_type'), true) }}"
  26. gce_machine_image: "{{ lookup('env', 'gce_machine_node_image') | default(lookup('env', 'gce_machine_image'), true) }}"
  27. - include: ../../common/openshift-cluster/tasks/set_node_launch_facts.yml
  28. vars:
  29. type: "infra"
  30. count: "{{ num_infra }}"
  31. - include: tasks/launch_instances.yml
  32. vars:
  33. instances: "{{ node_names }}"
  34. cluster: "{{ cluster_id }}"
  35. type: "{{ k8s_type }}"
  36. g_sub_host_type: "{{ sub_host_type }}"
  37. gce_machine_type: "{{ lookup('env', 'gce_machine_node_type') | default(lookup('env', 'gce_machine_type'), true) }}"
  38. gce_machine_image: "{{ lookup('env', 'gce_machine_node_image') | default(lookup('env', 'gce_machine_image'), true) }}"
  39. - include: scaleup.yml
  40. - include: list.yml