cluster_hosts.yml 1.1 KB

1234567891011121314151617181920
  1. ---
  2. etcd_hosts: "{{ (groups['tag_host-type_etcd']|default([])
  3. | intersect((groups['tag_clusterid_' ~ cluster_id]|default([])))
  4. | intersect((groups['tag_environment_' ~ cluster_env]|default([]))) }}"
  5. lb_hosts: "{{ (groups['tag_host-type_lb']|default([]))
  6. | intersect((groups['tag_clusterid_' ~ cluster_id]|default([])))
  7. | intersect((groups['tag_environment_' ~ cluster_env]|default([]))) }}"
  8. master_hosts: "{{ (groups['tag_host-type_master']|default([]))
  9. | intersect((groups['tag_clusterid_' ~ cluster_id]|default([])))
  10. | intersect((groups['tag_environment_' ~ cluster_env]|default([]))) }}"
  11. node_hosts: "{{ (groups['tag_host-type_node']|default([]))
  12. | intersect((groups['tag_clusterid_' ~ cluster_id]|default([])))
  13. | intersect((groups['tag_environment_' ~ cluster_env]|default([]))) }}"
  14. nfs_hosts: "{{ (groups['tag_host-type_nfs']|default([]))
  15. | intersect((groups['tag_env_' ~ cluster_id]|default([]))) }}"