Remove unused NUM_OPENSTACK_SITES 11/75211/5
authorSam Hague <shague@redhat.com>
Wed, 15 Aug 2018 19:01:54 +0000 (15:01 -0400)
committerSam Hague <shague@redhat.com>
Wed, 15 Aug 2018 20:35:10 +0000 (16:35 -0400)
Change-Id: Ib41b2058cf3b1bb1b91683d2e17954bfd0e43ded
Signed-off-by: Sam Hague <shague@redhat.com>
jjb/integration/common-functions.sh
jjb/integration/integration-deploy-openstack-run-test.sh
jjb/integration/integration-get-slave-addresses.sh
jjb/integration/integration-templates.yaml

index 6cc4af21050ab577da58c3baf44d09000673f488..0d7a9e09138c8f2712d3a49b4c5934e3394c448f 100644 (file)
@@ -256,7 +256,6 @@ PUBLIC_PHYSICAL_NETWORK: ${PUBLIC_PHYSICAL_NETWORK}
 ENABLE_NETWORKING_L2GW: ${ENABLE_NETWORKING_L2GW}
 CREATE_INITIAL_NETWORKS: ${CREATE_INITIAL_NETWORKS}
 LBAAS_SERVICE_PROVIDER: ${LBAAS_SERVICE_PROVIDER}
-NUM_OPENSTACK_SITES: ${NUM_OPENSTACK_SITES}
 ODL_SFC_DRIVER: ${ODL_SFC_DRIVER}
 ODL_SNAT_MODE: ${ODL_SNAT_MODE}
 
index accea4a0b921dcb62ee82694cd43fdebfe4c2820..a48a9718e4397e5d58817c774f6f9a38842ae462 100644 (file)
@@ -709,31 +709,22 @@ sudo nova-manage db sync
 sudo nova-manage cell_v2 discover_hosts
 EOF
 
-NUM_OPENSTACK_SITES=${NUM_OPENSTACK_SITES:-1}
-compute_index=1
-odl_index=1
 os_node_list=()
-os_interval=$(( ${NUM_OPENSTACK_SYSTEM} / ${NUM_OPENSTACK_SITES} ))
-ha_proxy_index=${os_interval}
-
-for i in `seq 1 ${NUM_OPENSTACK_SITES}`; do
-    if [ "${ENABLE_HAPROXY_FOR_NEUTRON}" == "yes" ]; then
-        echo "Configure HAProxy"
-        ODL_HAPROXYIP_PARAM=OPENSTACK_HAPROXY_${i}_IP
-        ha_proxy_index=$(( $ha_proxy_index + $os_interval ))
-        odl_index=$(((i - 1) * 3 + 1))
-        ODL_IP_PARAM1=ODL_SYSTEM_$((odl_index++))_IP
-        ODL_IP_PARAM2=ODL_SYSTEM_$((odl_index++))_IP
-        ODL_IP_PARAM3=ODL_SYSTEM_$((odl_index++))_IP
-        ODLMGRIP[$i]=${!ODL_HAPROXYIP_PARAM} # ODL Northbound uses HAProxy VIP
-        ODL_OVS_MGRS[$i]="${!ODL_IP_PARAM1},${!ODL_IP_PARAM2},${!ODL_IP_PARAM3}" # OVSDB connects to all ODL IPs
-        configure_haproxy_for_neutron_requests ${!ODL_HAPROXYIP_PARAM} "${ODL_OVS_MGRS[$i]}"
-    else
-        ODL_IP_PARAM=ODL_SYSTEM_${i}_IP
-        ODL_OVS_MGRS[$i]="${!ODL_IP_PARAM}" # ODL Northbound uses ODL IP
-        ODLMGRIP[$i]=${!ODL_IP_PARAM} # OVSDB connects to ODL IP
-    fi
-done
+
+if [ "${ENABLE_HAPROXY_FOR_NEUTRON}" == "yes" ]; then
+    echo "Configure HAProxy"
+    ODL_HAPROXYIP_PARAM=OPENSTACK_HAPROXY_${i}_IP
+    ODL_IP_PARAM1=ODL_SYSTEM_1_IP
+    ODL_IP_PARAM2=ODL_SYSTEM_2_IP
+    ODL_IP_PARAM3=ODL_SYSTEM_3_IP
+    ODLMGRIP=${!ODL_HAPROXYIP_PARAM} # ODL Northbound uses HAProxy VIP
+    ODL_OVS_MGRS="${!ODL_IP_PARAM1},${!ODL_IP_PARAM2},${!ODL_IP_PARAM3}" # OVSDB connects to all ODL IPs
+    configure_haproxy_for_neutron_requests ${!ODL_HAPROXYIP_PARAM} "${ODL_OVS_MGRS}"
+else
+    ODL_IP_PARAM=ODL_SYSTEM_1_IP
+    ODLMGRIP=${!ODL_IP_PARAM} # OVSDB connects to ODL IP
+    ODL_OVS_MGRS="${!ODL_IP_PARAM}" # ODL Northbound uses ODL IP
+fi
 
 os_ip_list=()
 for i in `seq 1 ${NUM_OPENSTACK_CONTROL_NODES}`; do
@@ -774,7 +765,7 @@ for i in `seq 1 ${NUM_OPENSTACK_CONTROL_NODES}`; do
        ssh ${!CONTROLIP} "sed -i 's/flat_networks public/flat_networks public,physnet1/' /opt/stack/devstack/lib/neutron"
        ssh ${!CONTROLIP} "sed -i '186i iniset \$NEUTRON_CORE_PLUGIN_CONF ml2_type_vlan network_vlan_ranges public:1:4094,physnet1:1:4094' /opt/stack/devstack/lib/neutron"
     fi
-    create_control_node_local_conf ${!CONTROLIP} ${ODLMGRIP[$i]} "${ODL_OVS_MGRS[$i]}"
+    create_control_node_local_conf ${!CONTROLIP} ${ODLMGRIP} "${ODL_OVS_MGRS}"
     scp ${WORKSPACE}/local.conf_control_${!CONTROLIP} ${!CONTROLIP}:/opt/stack/devstack/local.conf
     echo "Install rdo release to avoid incompatible Package versions"
     install_rdo_release ${!CONTROLIP}
@@ -817,10 +808,8 @@ if [ ${NUM_OPENSTACK_COMPUTE_NODES} -gt 0 ]; then
 fi
 
 for i in `seq 1 ${NUM_OPENSTACK_COMPUTE_NODES}`; do
-    NUM_COMPUTES_PER_SITE=$((NUM_OPENSTACK_COMPUTE_NODES / NUM_OPENSTACK_SITES))
-    SITE_INDEX=$((((i - 1) / NUM_COMPUTES_PER_SITE) + 1)) # We need the site index to infer the control node IP for this compute
     COMPUTEIP=OPENSTACK_COMPUTE_NODE_${i}_IP
-    CONTROLIP=OPENSTACK_CONTROL_NODE_${SITE_INDEX}_IP
+    CONTROLIP=OPENSTACK_CONTROL_NODE_1_IP
     echo "Configure the stack of the compute node ${i} of ${NUM_OPENSTACK_COMPUTE_NODES}: ${!COMPUTEIP}"
     scp ${WORKSPACE}/disable_firewall.sh "${!COMPUTEIP}:/tmp"
     ${SSH} "${!COMPUTEIP}" "sudo bash /tmp/disable_firewall.sh"
@@ -828,7 +817,7 @@ for i in `seq 1 ${NUM_OPENSTACK_COMPUTE_NODES}`; do
     scp ${WORKSPACE}/hosts_file ${!COMPUTEIP}:/tmp/hosts
     scp ${WORKSPACE}/get_devstack.sh  ${!COMPUTEIP}:/tmp
     ${SSH} ${!COMPUTEIP} "bash /tmp/get_devstack.sh > /tmp/get_devstack.sh.txt 2>&1"
-    create_compute_node_local_conf ${!COMPUTEIP} ${!CONTROLIP} ${ODLMGRIP[$SITE_INDEX]} "${ODL_OVS_MGRS[$SITE_INDEX]}"
+    create_compute_node_local_conf ${!COMPUTEIP} ${!CONTROLIP} ${ODLMGRIP} "${ODL_OVS_MGRS}"
     scp ${WORKSPACE}/local.conf_compute_${!COMPUTEIP} ${!COMPUTEIP}:/opt/stack/devstack/local.conf
     echo "Install rdo release to avoid incompatible Package versions"
     install_rdo_release ${!COMPUTEIP}
@@ -899,122 +888,111 @@ while [ ${in_progress} -eq 1 ]; do
 done
 
 # Further configuration now that stacking is complete.
-NUM_COMPUTES_PER_SITE=$((NUM_OPENSTACK_COMPUTE_NODES / NUM_OPENSTACK_SITES))
-for i in `seq 1 ${NUM_OPENSTACK_SITES}`; do
-    echo "Configure the Control Node"
-    CONTROLIP=OPENSTACK_CONTROL_NODE_${i}_IP
-    # Gather Compute IPs for the site
-    for j in `seq 1 ${NUM_COMPUTES_PER_SITE}`; do
-        COMPUTE_INDEX=$(((i-1) * NUM_COMPUTES_PER_SITE + j))
-        IP_VAR=OPENSTACK_COMPUTE_NODE_${COMPUTE_INDEX}_IP
-        COMPUTE_IPS[$((j-1))]=${!IP_VAR}
-    done
+echo "Configure the Control Node"
+CONTROLIP=OPENSTACK_CONTROL_NODE_1_IP
+# Gather Compute IPs for the site
+for i in `seq 1 ${NUM_OPENSTACK_COMPUTE_NODES}`; do
+    IP_VAR=OPENSTACK_COMPUTE_NODE_${i}_IP
+    COMPUTE_IPS[$((i-1))]=${!IP_VAR}
+done
 
-    echo "sleep for 60s and print hypervisor-list"
-    sleep 60
-    ${SSH} ${!CONTROLIP} "cd /opt/stack/devstack; source openrc admin admin; nova hypervisor-list"
-    # in the case that we are doing openstack (control + compute) all in one node, then the number of hypervisors
-    # will be the same as the number of openstack systems. However, if we are doing multinode openstack then the
-    # assumption is we have a single control node and the rest are compute nodes, so the number of expected hypervisors
-    # is one less than the total number of openstack systems
-    if [ $((NUM_OPENSTACK_SYSTEM / NUM_OPENSTACK_SITES)) -eq 1 ]; then
-        expected_num_hypervisors=1
-    else
-        expected_num_hypervisors=${NUM_COMPUTES_PER_SITE}
-        if [ "$(is_openstack_feature_enabled n-cpu)" == "1" ]; then
-            expected_num_hypervisors=$((expected_num_hypervisors + 1))
-        fi
-    fi
-    num_hypervisors=$(${SSH} ${!CONTROLIP} "cd /opt/stack/devstack; source openrc admin admin; openstack hypervisor list -f value | wc -l" | tail -1 | tr -d "\r")
-    if ! [ "${num_hypervisors}" ] || ! [ ${num_hypervisors} -eq ${expected_num_hypervisors} ]; then
-        echo "Error: Only $num_hypervisors hypervisors detected, expected $expected_num_hypervisors"
-        exit 1
+echo "sleep for 60s and print hypervisor-list"
+sleep 60
+${SSH} ${!CONTROLIP} "cd /opt/stack/devstack; source openrc admin admin; nova hypervisor-list"
+# in the case that we are doing openstack (control + compute) all in one node, then the number of hypervisors
+# will be the same as the number of openstack systems. However, if we are doing multinode openstack then the
+# assumption is we have a single control node and the rest are compute nodes, so the number of expected hypervisors
+# is one less than the total number of openstack systems
+if [ ${NUM_OPENSTACK_SYSTEM} -eq 1 ]; then
+    expected_num_hypervisors=1
+else
+    expected_num_hypervisors=$(NUM_OPENSTACK_COMPUTE_NODES)
+    if [ "$(is_openstack_feature_enabled n-cpu)" == "1" ]; then
+        expected_num_hypervisors=$((expected_num_hypervisors + 1))
     fi
+fi
+num_hypervisors=$(${SSH} ${!CONTROLIP} "cd /opt/stack/devstack; source openrc admin admin; openstack hypervisor list -f value | wc -l" | tail -1 | tr -d "\r")
+if ! [ "${num_hypervisors}" ] || ! [ ${num_hypervisors} -eq ${expected_num_hypervisors} ]; then
+    echo "Error: Only $num_hypervisors hypervisors detected, expected $expected_num_hypervisors"
+    exit 1
+fi
+
+# External Network
+echo "prepare external networks by adding vxlan tunnels between all nodes on a separate bridge..."
+# FIXME Should there be a unique gateway IP and devstack index for each site?
+devstack_index=1
+for ip in ${!CONTROLIP} ${COMPUTE_IPS[*]}; do
+    # FIXME - Workaround, ODL (new netvirt) currently adds PUBLIC_BRIDGE as a port in br-int since it doesn't see such a bridge existing when we stack
+    ${SSH} $ip "sudo ovs-vsctl --if-exists del-port br-int $PUBLIC_BRIDGE"
+    ${SSH} $ip "sudo ovs-vsctl --may-exist add-br $PUBLIC_BRIDGE -- set bridge $PUBLIC_BRIDGE other-config:disable-in-band=true other_config:hwaddr=f6:00:00:ff:01:0$((devstack_index++))"
+done
 
-    # Gather Compute IPs for the site
-    for j in `seq 1 ${NUM_COMPUTES_PER_SITE}`; do
-        COMPUTE_INDEX=$(((i-1) * NUM_COMPUTES_PER_SITE + j))
-        IP_VAR=OPENSTACK_COMPUTE_NODE_${COMPUTE_INDEX}_IP
-        COMPUTE_IPS[$((j-1))]=${!IP_VAR}
+# ipsec support
+if [ "${IPSEC_VXLAN_TUNNELS_ENABLED}" == "yes" ]; then
+    # shellcheck disable=SC2206
+    ALL_NODES=(${!CONTROLIP} ${COMPUTE_IPS[*]})
+    for ((inx_ip1=0; inx_ip1<$((${#ALL_NODES[@]} - 1)); inx_ip1++)); do
+        for ((inx_ip2=$((inx_ip1 + 1)); inx_ip2<${#ALL_NODES[@]}; inx_ip2++)); do
+            KEY1=0x$(dd if=/dev/urandom count=32 bs=1 2> /dev/null| xxd -p -c 64)
+            KEY2=0x$(dd if=/dev/urandom count=32 bs=1 2> /dev/null| xxd -p -c 64)
+            ID=0x$(dd if=/dev/urandom count=4 bs=1 2> /dev/null| xxd -p -c 8)
+            ip1=${ALL_NODES[$inx_ip1]}
+            ip2=${ALL_NODES[$inx_ip2]}
+            ${SSH} $ip1 "sudo ip xfrm state add src $ip1 dst $ip2 proto esp spi $ID reqid $ID mode transport auth sha256 $KEY1 enc aes $KEY2"
+            ${SSH} $ip1 "sudo ip xfrm state add src $ip2 dst $ip1 proto esp spi $ID reqid $ID mode transport auth sha256 $KEY1 enc aes $KEY2"
+            ${SSH} $ip1 "sudo ip xfrm policy add src $ip1 dst $ip2 proto udp dir out tmpl src $ip1 dst $ip2 proto esp reqid $ID mode transport"
+            ${SSH} $ip1 "sudo ip xfrm policy add src $ip2 dst $ip1 proto udp dir in tmpl src $ip2 dst $ip1 proto esp reqid $ID mode transport"
+
+            ${SSH} $ip2 "sudo ip xfrm state add src $ip2 dst $ip1 proto esp spi $ID reqid $ID mode transport auth sha256 $KEY1 enc aes $KEY2"
+            ${SSH} $ip2 "sudo ip xfrm state add src $ip1 dst $ip2 proto esp spi $ID reqid $ID mode transport auth sha256 $KEY1 enc aes $KEY2"
+            ${SSH} $ip2 "sudo ip xfrm policy add src $ip2 dst $ip1 proto udp dir out tmpl src $ip2 dst $ip1 proto esp reqid $ID mode transport"
+            ${SSH} $ip2 "sudo ip xfrm policy add src $ip1 dst $ip2 proto udp dir in tmpl src $ip1 dst $ip2 proto esp reqid $ID mode transport"
+        done
     done
 
-    # External Network
-    echo "prepare external networks by adding vxlan tunnels between all nodes on a separate bridge..."
-    # FIXME Should there be a unique gateway IP and devstack index for each site?
-    devstack_index=1
     for ip in ${!CONTROLIP} ${COMPUTE_IPS[*]}; do
-        # FIXME - Workaround, ODL (new netvirt) currently adds PUBLIC_BRIDGE as a port in br-int since it doesn't see such a bridge existing when we stack
-        ${SSH} $ip "sudo ovs-vsctl --if-exists del-port br-int $PUBLIC_BRIDGE"
-        ${SSH} $ip "sudo ovs-vsctl --may-exist add-br $PUBLIC_BRIDGE -- set bridge $PUBLIC_BRIDGE other-config:disable-in-band=true other_config:hwaddr=f6:00:00:ff:01:0$((devstack_index++))"
+        echo "ip xfrm configuration for node $ip:"
+        ${SSH} $ip "sudo ip xfrm policy list"
+        ${SSH} $ip "sudo ip xfrm state list"
     done
+fi
 
-    # ipsec support
-    if [ "${IPSEC_VXLAN_TUNNELS_ENABLED}" == "yes" ]; then
-        # shellcheck disable=SC2206
-        ALL_NODES=(${!CONTROLIP} ${COMPUTE_IPS[*]})
-        for ((inx_ip1=0; inx_ip1<$((${#ALL_NODES[@]} - 1)); inx_ip1++)); do
-            for ((inx_ip2=$((inx_ip1 + 1)); inx_ip2<${#ALL_NODES[@]}; inx_ip2++)); do
-                KEY1=0x$(dd if=/dev/urandom count=32 bs=1 2> /dev/null| xxd -p -c 64)
-                KEY2=0x$(dd if=/dev/urandom count=32 bs=1 2> /dev/null| xxd -p -c 64)
-                ID=0x$(dd if=/dev/urandom count=4 bs=1 2> /dev/null| xxd -p -c 8)
-                ip1=${ALL_NODES[$inx_ip1]}
-                ip2=${ALL_NODES[$inx_ip2]}
-                ${SSH} $ip1 "sudo ip xfrm state add src $ip1 dst $ip2 proto esp spi $ID reqid $ID mode transport auth sha256 $KEY1 enc aes $KEY2"
-                ${SSH} $ip1 "sudo ip xfrm state add src $ip2 dst $ip1 proto esp spi $ID reqid $ID mode transport auth sha256 $KEY1 enc aes $KEY2"
-                ${SSH} $ip1 "sudo ip xfrm policy add src $ip1 dst $ip2 proto udp dir out tmpl src $ip1 dst $ip2 proto esp reqid $ID mode transport"
-                ${SSH} $ip1 "sudo ip xfrm policy add src $ip2 dst $ip1 proto udp dir in tmpl src $ip2 dst $ip1 proto esp reqid $ID mode transport"
-
-                ${SSH} $ip2 "sudo ip xfrm state add src $ip2 dst $ip1 proto esp spi $ID reqid $ID mode transport auth sha256 $KEY1 enc aes $KEY2"
-                ${SSH} $ip2 "sudo ip xfrm state add src $ip1 dst $ip2 proto esp spi $ID reqid $ID mode transport auth sha256 $KEY1 enc aes $KEY2"
-                ${SSH} $ip2 "sudo ip xfrm policy add src $ip2 dst $ip1 proto udp dir out tmpl src $ip2 dst $ip1 proto esp reqid $ID mode transport"
-                ${SSH} $ip2 "sudo ip xfrm policy add src $ip1 dst $ip2 proto udp dir in tmpl src $ip1 dst $ip2 proto esp reqid $ID mode transport"
-            done
-        done
-
-        for ip in ${!CONTROLIP} ${COMPUTE_IPS[*]}; do
-            echo "ip xfrm configuration for node $ip:"
-            ${SSH} $ip "sudo ip xfrm policy list"
-            ${SSH} $ip "sudo ip xfrm state list"
-        done
-    fi
-
-    # Control Node - PUBLIC_BRIDGE will act as the external router
-    # Parameter values below are used in integration/test - changing them requires updates in intergration/test as well
-    EXTNET_GATEWAY_IP="10.10.10.250"
-    EXTNET_INTERNET_IP="10.9.9.9"
-    EXTNET_PNF_IP="10.10.10.253"
-    ${SSH} ${!CONTROLIP} "sudo ifconfig ${PUBLIC_BRIDGE} up ${EXTNET_GATEWAY_IP}/24"
-
-    # Control Node - external net PNF simulation
+# Control Node - PUBLIC_BRIDGE will act as the external router
+# Parameter values below are used in integration/test - changing them requires updates in intergration/test as well
+EXTNET_GATEWAY_IP="10.10.10.250"
+EXTNET_INTERNET_IP="10.9.9.9"
+EXTNET_PNF_IP="10.10.10.253"
+${SSH} ${!CONTROLIP} "sudo ifconfig ${PUBLIC_BRIDGE} up ${EXTNET_GATEWAY_IP}/24"
+
+# Control Node - external net PNF simulation
+${SSH} ${!CONTROLIP} "
+    sudo ip netns add pnf_ns;
+    sudo ip link add pnf_veth0 type veth peer name pnf_veth1;
+    sudo ip link set pnf_veth1 netns pnf_ns;
+    sudo ip link set pnf_veth0 up;
+    sudo ip netns exec pnf_ns ifconfig pnf_veth1 up ${EXTNET_PNF_IP}/24;
+    sudo ovs-vsctl add-port ${PUBLIC_BRIDGE} pnf_veth0;
+"
+
+# Control Node - external net internet address simulation
+${SSH} ${!CONTROLIP} "
+    sudo ip tuntap add dev internet_tap mode tap;
+    sudo ifconfig internet_tap up ${EXTNET_INTERNET_IP}/24;
+"
+
+# Computes
+compute_index=1
+for compute_ip in ${COMPUTE_IPS[*]}; do
+    # Tunnel from controller to compute
+    COMPUTEPORT=compute$(( compute_index++ ))_vxlan
     ${SSH} ${!CONTROLIP} "
-        sudo ip netns add pnf_ns;
-        sudo ip link add pnf_veth0 type veth peer name pnf_veth1;
-        sudo ip link set pnf_veth1 netns pnf_ns;
-        sudo ip link set pnf_veth0 up;
-        sudo ip netns exec pnf_ns ifconfig pnf_veth1 up ${EXTNET_PNF_IP}/24;
-        sudo ovs-vsctl add-port ${PUBLIC_BRIDGE} pnf_veth0;
+        sudo ovs-vsctl add-port $PUBLIC_BRIDGE $COMPUTEPORT -- set interface $COMPUTEPORT type=vxlan options:local_ip=${!CONTROLIP} options:remote_ip=$compute_ip options:dst_port=9876 options:key=flow
     "
-
-    # Control Node - external net internet address simulation
-    ${SSH} ${!CONTROLIP} "
-        sudo ip tuntap add dev internet_tap mode tap;
-        sudo ifconfig internet_tap up ${EXTNET_INTERNET_IP}/24;
+    # Tunnel from compute to controller
+    CONTROLPORT="control_vxlan"
+    ${SSH} $compute_ip "
+        sudo ovs-vsctl add-port $PUBLIC_BRIDGE $CONTROLPORT -- set interface $CONTROLPORT type=vxlan options:local_ip=$compute_ip options:remote_ip=${!CONTROLIP} options:dst_port=9876 options:key=flow
     "
-
-    # Computes
-    compute_index=1
-    for compute_ip in ${COMPUTE_IPS[*]}; do
-        # Tunnel from controller to compute
-        COMPUTEPORT=compute$(( compute_index++ ))_vxlan
-        ${SSH} ${!CONTROLIP} "
-            sudo ovs-vsctl add-port $PUBLIC_BRIDGE $COMPUTEPORT -- set interface $COMPUTEPORT type=vxlan options:local_ip=${!CONTROLIP} options:remote_ip=$compute_ip options:dst_port=9876 options:key=flow
-        "
-        # Tunnel from compute to controller
-        CONTROLPORT="control_vxlan"
-        ${SSH} $compute_ip "
-            sudo ovs-vsctl add-port $PUBLIC_BRIDGE $CONTROLPORT -- set interface $CONTROLPORT type=vxlan options:local_ip=$compute_ip options:remote_ip=${!CONTROLIP} options:dst_port=9876 options:key=flow
-        "
-    done
 done
 
 if [ "${ENABLE_HAPROXY_FOR_NEUTRON}" == "yes" ]; then
@@ -1125,7 +1103,6 @@ for suite in ${SUITES}; do
     -v JENKINS_WORKSPACE:${WORKSPACE} \
     -v NEXUSURL_PREFIX:${NEXUSURL_PREFIX} \
     -v NUM_ODL_SYSTEM:${NUM_ODL_SYSTEM} \
-    -v NUM_OPENSTACK_SITES:${NUM_OPENSTACK_SITES} \
     -v NUM_OS_SYSTEM:${NUM_OPENSTACK_SYSTEM} \
     -v NUM_TOOLS_SYSTEM:${NUM_TOOLS_SYSTEM} \
     -v ODL_SNAT_MODE:${ODL_SNAT_MODE} \
index 816dcf80a72515593df804d1510abcee0bdac5a8..9f57dfc7ae72388bb329bfc6da15c2545330008c 100644 (file)
@@ -7,7 +7,6 @@ ODL_SYSTEM=()
 TOOLS_SYSTEM=()
 OPENSTACK_SYSTEM=()
 OPENSTACK_CONTROLLERS=()
-[ "$NUM_OPENSTACK_SITES" ] || NUM_OPENSTACK_SITES=1
 
 OPENSTACK_VENV="/tmp/v/openstack"
 # shellcheck source=/tmp/v/openstack/bin/activate disable=SC1091
@@ -54,7 +53,7 @@ echo "NUM_TOOLS_SYSTEM=${#TOOLS_SYSTEM[@]}" >> slave_addresses.txt
 #if HA Proxy is requested the last devstack node will be configured as haproxy
 if [ "${ENABLE_HAPROXY_FOR_NEUTRON}" == "yes" ]; then
    # HA Proxy is installed on one OPENSTACK_SYSTEM VM on each site
-   NUM_OPENSTACK_SYSTEM=$(( ${#OPENSTACK_SYSTEM[@]} - NUM_OPENSTACK_SITES ))
+   NUM_OPENSTACK_SYSTEM=$(( ${#OPENSTACK_SYSTEM[@]} - 1 ))
 else
    NUM_OPENSTACK_SYSTEM=${#OPENSTACK_SYSTEM[@]}
 fi
@@ -91,7 +90,7 @@ done
 
 openstack_index=0
 # Assuming number of openstack control nodes equals number of openstack sites
-NUM_OPENSTACK_CONTROL_NODES=$(( NUM_OPENSTACK_SITES ))
+NUM_OPENSTACK_CONTROL_NODES=1
 echo "NUM_OPENSTACK_CONTROL_NODES=${NUM_OPENSTACK_CONTROL_NODES}" >> slave_addresses.txt
 for i in $(seq 0 $((NUM_OPENSTACK_CONTROL_NODES - 1)))
 do
index 7ad19c5e7afeb6a599b515bae9ac6b5fb7d1657f..c5a7861a5405ad9753e522a2ce709ea1ca6943d3 100644 (file)
           default: '{lbaas-service-provider}'
           description: 'The NEUTRON_LBAAS_SERVICE_PROVIDERV2 value to be used in local.conf - only relevant when using
           neutron-lbaas'
-      - string:
-          name: NUM_OPENSTACK_SITES
-          default: '{num-openstack-sites}'
-          description: 'Number of openstack sites'
       - string:
           name: ODL_SFC_DRIVER
           default: '{odl-sfc-driver}'