1 ##############################################################################
2 # Copyright (c) 2016 HUAWEI TECHNOLOGIES CO.,LTD and others.
4 # All rights reserved. This program and the accompanying materials
5 # are made available under the terms of the Apache License, Version 2.0
6 # which accompanies this distribution, and is available at
7 # http://www.apache.org/licenses/LICENSE-2.0
8 ##############################################################################
11 - name: combine odl controller
12 shell: rm -f /opt/cluster; touch /opt/cluster;
14 - name: combine odl controller
15 shell: echo "{{ ip_settings[item.1]['mgmt']['ip'] }} \c" >> /opt/cluster; >> /opt/cluster;
16 with_indexed_items: groups['odl']
18 - name: combine odl controller
19 shell: cat /opt/cluster
22 #- debug: msg="{{ cluster.stdout_lines[0] }}"
24 - name: combine odl controller
25 shell: uname -n | cut -b 5,5
28 #- debug: msg="{{ number.stdout_lines[0] }}"
30 - debug: msg="{{ odl_home }}/bin/configure_cluster.sh {{ number.stdout_lines[0] }} {{ cluster.stdout_lines[0] }}"
32 - name: configure odl controller in cluster
33 shell: "{{ odl_home }}/bin/configure_cluster.sh {{ number.stdout_lines[0] }} {{ cluster.stdout_lines[0] }}"