Move deploy options check to network settings section 79/18679/2
authorFeng Pan <fpan@redhat.com>
Mon, 15 Aug 2016 14:28:25 +0000 (10:28 -0400)
committerFeng Pan <fpan@redhat.com>
Mon, 15 Aug 2016 14:34:00 +0000 (10:34 -0400)
JIRA: APEX-228

Change-Id: I85e6794bf2371116facef60ef4e29c9c9ca79131
Signed-off-by: Feng Pan <fpan@redhat.com>
lib/parse-functions.sh

index 0be62e2..9695405 100755 (executable)
@@ -70,6 +70,17 @@ parse_network_settings() {
       echo -e "${red}ERROR: Failed to parse network settings file $NETSETS ${reset}"
       exit 1
   fi
+
+  if [ "${deploy_options_array['dataplane']}" == 'ovs_dpdk' ]; then
+    if [ "$net_isolation_enabled" == "FALSE" ]; then
+      echo -e "${red}ERROR: flat network is not supported with ovs-dpdk ${reset}"
+      exit 1
+    fi
+    if [[ ! $enabled_network_list =~ "private_network" ]]; then
+      echo -e "${red}ERROR: tenant network is not enabled for ovs-dpdk ${reset}"
+      exit 1
+    fi
+  fi
 }
 
 ##parses deploy settings yaml into globals
@@ -83,16 +94,6 @@ parse_deploy_settings() {
       exit 1
   fi
 
-  if [ "${deploy_options_array['dataplane']}" == 'ovs_dpdk' ]; then
-    if [ "$net_isolation_enabled" == "FALSE" ]; then
-      echo -e "${red}ERROR: flat network is not supported with ovs-dpdk ${reset}"
-      exit 1
-    fi
-    if [[ ! $enabled_network_list =~ "private_network" ]]; then
-      echo -e "${red}ERROR: tenant network is not enabled for ovs-dpdk ${reset}"
-      exit 1
-    fi
-  fi
 }
 
 ##parses baremetal yaml settings into compatible json