############################################################################## # Copyright (c) 2016 HUAWEI TECHNOLOGIES CO.,LTD and others. # # All rights reserved. This program and the accompanying materials # are made available under the terms of the Apache License, Version 2.0 # which accompanies this distribution, and is available at # http://www.apache.org/licenses/LICENSE-2.0 ############################################################################## --- - name: load storage.yml include: storage.yml when: - hostvars[inventory_hostname]['groups']['ceph_mon'] is not defined - hostvars[inventory_hostname]['groups']['ceph_osd'] is not defined tags: - storage - name: load ceph.yml include: ceph.yml when: - hostvars[inventory_hostname]['groups']['ceph_mon'] is defined and "{{ hostvars[inventory_hostname]['groups']['ceph_mon'] | length > 0 }}" - hostvars[inventory_hostname]['groups']['ceph_osd'] is defined and "{{ hostvars[inventory_hostname]['groups']['ceph_osd'] | length > 0 }}" tags: - storage - meta: flush_handlers