refresh-completed always failing

99-refresh-completed is always failing for me know.

The review I69d9103b07100f700fb71a2cbbf267042625e7a7 was failing the
non-voting CI but was merged in any ways. This patch tried to put
all the if logic on one line but was too smart for its own good as
kept getting the following error in os-collect-config:

+ curl -X PUT -H Content-Type: --data-binary '{"Status" : "SUCCESS","Reason" : "Configuration Complete","UniqueId" : "i-00000001","Data" : "Finished os-refresh-config."}' 'http://192.0.2.1:8000/v1/waitcondition/arn%3Aopenstack%3Aheat%3A%3A5cb53cbf0dad47cf9fcc4761e79a6a53%3Astacks%2Fundercloud%2F6411748e-ee64-4467-a81f-a4d0e8bb097b%2Fresources%2FnotCompute0CompletionHandle?Timestamp=2014-04-09T14%3A56%3A50Z&SignatureMethod=HmacSHA256&AWSAccessKeyId=50006a08504d41c39402ae0423cab992&SignatureVersion=2&Signature=A89ZrnQr6ZE8caXcn4uDY8sNE%2FbjmcsyXESzaQdG6fg%3D'
<resource>notCompute0CompletionHandle</resource>+ '[' -n '' ']'
[2014-04-09 15:03:23,550] (os-refresh-config) [ERROR] during post-configure phase. [Command '['dib-run-parts', '/opt/stack/os-config-refresh/post-configure.d']' returned non-zero exit status 1]

Change-Id: I0bf2ecfdad299b27b47a27496f9a833efa039206
This commit is contained in:
Michael Kerrin 2014-04-09 11:25:05 -04:00
parent 91b77ae23b
commit 721cedc2e6
1 changed files with 6 additions and 2 deletions

View File

@ -14,5 +14,9 @@ call_curl() {
}
# Signals use POST, wait handles use PUT
[ -n "$HANDLE" ] && call_curl PUT $HANDLE
[ -n "$SIGNAL" ] && call_curl POST $SIGNAL
if [ -n "$HANDLE" ]; then
call_curl PUT $HANDLE
fi
if [ -n "$SIGNAL" ]; then
call_curl POST $SIGNAL
fi