summaryrefslogtreecommitdiffstats
path: root/lib
diff options
context:
space:
mode:
Diffstat (limited to 'lib')
-rwxr-xr-xlib/post-install-functions.sh12
-rw-r--r--lib/python/apex/deploy_env.py2
-rw-r--r--lib/python/apex/network_environment.py1
-rw-r--r--lib/utility-functions.sh13
4 files changed, 22 insertions, 6 deletions
diff --git a/lib/post-install-functions.sh b/lib/post-install-functions.sh
index 912a2a11..ec2ca89f 100755
--- a/lib/post-install-functions.sh
+++ b/lib/post-install-functions.sh
@@ -76,7 +76,11 @@ EOI
source overcloudrc
set -o errexit
echo "Configuring Neutron external network"
-neutron net-create external --router:external=True --tenant-id \$(openstack project show service | grep id | awk '{ print \$4 }')
+if [[ -n "$public_network_vlan" && "$public_network_vlan" != 'native' ]]; then
+ neutron net-create external --router:external=True --tenant-id \$(openstack project show service | grep id | awk '{ print \$4 }') --provider:network_type vlan --provider:segmentation_id ${public_network_vlan} --provider:physical_network datacentre
+else
+ neutron net-create external --router:external=True --tenant-id \$(openstack project show service | grep id | awk '{ print \$4 }')
+fi
neutron subnet-create --name external-net --tenant-id \$(openstack project show service | grep id | awk '{ print \$4 }') --disable-dhcp external --gateway ${public_network_gateway} --allocation-pool start=${public_network_floating_ip_range%%,*},end=${public_network_floating_ip_range##*,} ${public_network_cidr}
echo "Removing sahara endpoint and service"
@@ -127,6 +131,12 @@ done
EOI
fi
+ ### VSPERF ###
+ if [[ "${deploy_options_array['vsperf']}" == 'True' ]]; then
+ echo "${blue}\nVSPERF enabled, running build_base_machine.sh\n${reset}"
+ overcloud_connect "compute0" "sudo sh -c 'cd /var/opt/vsperf/systems/ && ./build_base_machine.sh 2>&1 > /var/log/vsperf.log'"
+ fi
+
# Collect deployment logs
ssh -T ${SSH_OPTIONS[@]} "stack@$UNDERCLOUD" <<EOI
mkdir -p ~/deploy_logs
diff --git a/lib/python/apex/deploy_env.py b/lib/python/apex/deploy_env.py
index 1fe137e4..816dc114 100644
--- a/lib/python/apex/deploy_env.py
+++ b/lib/python/apex/deploy_env.py
@@ -21,7 +21,7 @@ REQ_DEPLOY_SETTINGS = ['sdn_controller',
'vpn',
'vpp']
-OPT_DEPLOY_SETTINGS = ['performance']
+OPT_DEPLOY_SETTINGS = ['performance', 'vsperf']
VALID_ROLES = ['Controller', 'Compute', 'ObjectStorage']
VALID_PERF_OPTS = ['kernel', 'nova']
diff --git a/lib/python/apex/network_environment.py b/lib/python/apex/network_environment.py
index bf4bdc79..981c8f1c 100644
--- a/lib/python/apex/network_environment.py
+++ b/lib/python/apex/network_environment.py
@@ -84,6 +84,7 @@ class NetworkEnvironment:
public_cidr = net_settings[PUBLIC_NETWORK]['cidr']
self.netenv_obj[param_def]['ExternalNetCidr'] = str(public_cidr)
if net_settings[PUBLIC_NETWORK]['vlan'] != 'native':
+ self.netenv_obj[param_def]['NeutronExternalNetworkBridge'] = '""'
self.netenv_obj[param_def]['ExternalNetworkVlanID'] = \
net_settings[PUBLIC_NETWORK]['vlan']
public_range = \
diff --git a/lib/utility-functions.sh b/lib/utility-functions.sh
index 93050701..f73a2d85 100644
--- a/lib/utility-functions.sh
+++ b/lib/utility-functions.sh
@@ -15,14 +15,19 @@ function undercloud_connect {
fi
if [ -z "$2" ]; then
- ssh ${SSH_OPTIONS[@]} ${user}@$(arp -a | grep $(virsh domiflist undercloud | grep default |\
- awk '{print $5}') | grep -Eo "[0-9]+\.[0-9]+\.[0-9]+\.[0-9]+")
+ ssh ${SSH_OPTIONS[@]} ${user}@$(get_undercloud_ip)
else
- ssh ${SSH_OPTIONS[@]} -T ${user}@$(arp -a | grep $(virsh domiflist undercloud | grep default \
- | awk '{print $5}') | grep -Eo "[0-9]+\.[0-9]+\.[0-9]+\.[0-9]+") "$2"
+ ssh ${SSH_OPTIONS[@]} -T ${user}@$(get_undercloud_ip) "$2"
fi
}
+##outputs the Undercloud's IP address
+##params: none
+function get_undercloud_ip {
+ echo $(arp -a | grep $(virsh domiflist undercloud | grep default |\
+ awk '{print $5}') | grep -Eo "[0-9]+\.[0-9]+\.[0-9]+\.[0-9]+")
+}
+
##connects to overcloud nodes
##params: node to login to, command to execute on overcloud (optional)
function overcloud_connect {