Don't inherit enforcing bash errexit in devstack plugin

The devstack plugin code was sourcing a file that was
enabling bash errexit, which was then inheriting it in
later operations that could cause the shell to exit
unexpectedly.

Change both scripts to 'set +e' near exit so sourcing
them doesn't have issues.

Change-Id: I16513b0066c05cd6fc606da341df636094010a34
This commit is contained in:
Brian Haley 2020-04-14 13:42:43 -04:00
parent c9e1551550
commit 1c639f01a0
2 changed files with 6 additions and 0 deletions

View File

@ -146,6 +146,9 @@ echo "################# Verifying the Octavia files ###########################"
openssl verify -CAfile etc/octavia/certs/client_ca.cert.pem etc/octavia/certs/client.cert-and-key.pem
openssl verify -CAfile etc/octavia/certs/server_ca-chain.cert.pem etc/octavia/certs/server_ca.cert.pem
# We are done, stop enforcing shell errexit
set +e
echo "!!!!!!!!!!!!!!!Do not use this script for deployments!!!!!!!!!!!!!"
echo "Please use the Octavia Certificate Configuration guide:"
echo "https://docs.openstack.org/octavia/latest/admin/guides/certificates.html"

View File

@ -104,6 +104,9 @@ echo "################# Verifying the Octavia files ###########################"
openssl verify -CAfile etc/octavia/certs/client_ca.cert.pem etc/octavia/certs/client.cert-and-key.pem
openssl verify -CAfile etc/octavia/certs/server_ca.cert.pem etc/octavia/certs/server_ca.cert.pem
# We are done, stop enforcing shell errexit
set +e
echo "!!!!!!!!!!!!!!!Do not use this script for deployments!!!!!!!!!!!!!"
echo "Single CA mode is insecure, do not use this! It is for testing only."
echo "Please use the Octavia Certificate Configuration guide:"