From 1c639f01a083e32111306f1f8d1a89df6aea2950 Mon Sep 17 00:00:00 2001 From: Brian Haley Date: Tue, 14 Apr 2020 13:42:43 -0400 Subject: [PATCH] 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 --- bin/create_dual_intermediate_CA.sh | 3 +++ bin/create_single_CA_intermediate_CA.sh | 3 +++ 2 files changed, 6 insertions(+) diff --git a/bin/create_dual_intermediate_CA.sh b/bin/create_dual_intermediate_CA.sh index 6874f21336..89b822d439 100755 --- a/bin/create_dual_intermediate_CA.sh +++ b/bin/create_dual_intermediate_CA.sh @@ -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" diff --git a/bin/create_single_CA_intermediate_CA.sh b/bin/create_single_CA_intermediate_CA.sh index 445c6f5744..61cf1fd3ed 100755 --- a/bin/create_single_CA_intermediate_CA.sh +++ b/bin/create_single_CA_intermediate_CA.sh @@ -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:"