diff options
-rw-r--r-- | build/opnfv-apex-undercloud.spec | 8 | ||||
-rwxr-xr-x | ci/deploy.sh | 8 | ||||
-rw-r--r-- | lib/python/apex/deploy_env.py | 2 |
3 files changed, 7 insertions, 11 deletions
diff --git a/build/opnfv-apex-undercloud.spec b/build/opnfv-apex-undercloud.spec index 0e4798b3..55e152ff 100644 --- a/build/opnfv-apex-undercloud.spec +++ b/build/opnfv-apex-undercloud.spec @@ -25,17 +25,13 @@ mkdir -p %{buildroot}%{_var}/opt/opnfv/nics/ install build/undercloud.qcow2 %{buildroot}%{_var}/opt/opnfv/images/ install build/network-environment.yaml %{buildroot}%{_var}/opt/opnfv/ -install build/nics-controller.yaml.template %{buildroot}%{_var}/opt/opnfv/nics-controller.yaml.template -install build/nics-compute.yaml.template %{buildroot}%{_var}/opt/opnfv/nics-compute.yaml.template -install build/nics-controller.yaml.template %{buildroot}%{_var}/opt/opnfv/nics-controller.yaml.jinja2 -install build/nics-compute.yaml.template %{buildroot}%{_var}/opt/opnfv/nics-compute.yaml.jinja2 +install build/nics-controller.yaml.jinja2 %{buildroot}%{_var}/opt/opnfv/ +install build/nics-compute.yaml.jinja2 %{buildroot}%{_var}/opt/opnfv/ %files %defattr(644, root, root, -) %{_var}/opt/opnfv/images/undercloud.qcow2 %{_var}/opt/opnfv/network-environment.yaml -%{_var}/opt/opnfv/nics-controller.yaml.template -%{_var}/opt/opnfv/nics-compute.yaml.template %{_var}/opt/opnfv/nics-controller.yaml.jinja2 %{_var}/opt/opnfv/nics-compute.yaml.jinja2 diff --git a/ci/deploy.sh b/ci/deploy.sh index 18f96319..6b38c336 100755 --- a/ci/deploy.sh +++ b/ci/deploy.sh @@ -158,7 +158,7 @@ parse_inventory_file() { node_total=$node_count - if [[ "$node_total" -lt 5 && ( ha_enabled == "TRUE" || "$ha_enabled" == "true" ) ]]; then + if [[ "$node_total" -lt 5 && "$ha_enabled" == "True" ]]; then echo -e "${red}ERROR: You must provide at least 5 nodes for HA baremetal deployment${reset}" exit 1 elif [[ "$node_total" -lt 2 ]]; then @@ -835,7 +835,7 @@ function undercloud_prep_overcloud_deploy { total_nodes=$(ssh -T ${SSH_OPTIONS[@]} "root@$UNDERCLOUD" "cat /home/stack/instackenv.json | grep -c memory") # check if HA is enabled - if [[ "$ha_enabled" == "TRUE" || "$ha_enabled" == "true" ]]; then + if [[ "$ha_enabled" == "True" ]]; then DEPLOY_OPTIONS+=" --control-scale 3" compute_nodes=$((total_nodes - 3)) DEPLOY_OPTIONS+=" -e /usr/share/openstack-tripleo-heat-templates/environments/puppet-pacemaker.yaml" @@ -856,7 +856,7 @@ function undercloud_prep_overcloud_deploy { DEPLOY_OPTIONS+=" -e network-environment.yaml" fi - if [[ "$ha_enabled" == "TRUE" || "$ha_enabled" == "true" ]] || [[ "$net_isolation_enabled" == "TRUE" ]]; then + if [[ "$ha_enabled" == "True" ]] || [[ "$net_isolation_enabled" == "TRUE" ]]; then DEPLOY_OPTIONS+=" --ntp-server $ntp_server" fi @@ -1108,7 +1108,7 @@ parse_cmdline() { shift 1 ;; --no-ha ) - ha_enabled="FALSE" + ha_enabled="False" vm_index=1 echo "HA Deployment Disabled" shift 1 diff --git a/lib/python/apex/deploy_env.py b/lib/python/apex/deploy_env.py index 5c733248..be8779a9 100644 --- a/lib/python/apex/deploy_env.py +++ b/lib/python/apex/deploy_env.py @@ -129,7 +129,7 @@ class DeploySettings: """ bash_str = '' for key, value in self.deploy_settings['global_params'].items(): - bash_str += "if [ -z \"$(eval echo \$${})\" ]; then\n{}={}\nfi\n".format(key,key, value) + bash_str += "{}={}\n".format(key, value) if 'performance' in self.deploy_settings['deploy_options']: bash_str += self._dump_performance() bash_str += self._dump_deploy_options_array() |