-
Notifications
You must be signed in to change notification settings - Fork 13
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fixes #11 - Update sonar.sh to fail if rhc port-forward fails #20
Conversation
|
||
# wait a bit for port forwarding to fire up | ||
sleep 10 | ||
|
||
# if the file exists, log the error and exit 1 | ||
if [ -f "rhc-port-forward-status" ] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This check can come before the sleep 10
above so the script fails faster.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't think we should do that as the '&' would make the process run asynchronously in background , which it can take some time even to connect to the openshift, so the rhc command could not make the result in time to the if statement gives the right/expected output
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Good point, thank you.
Updated the commented line |
Two things to clean up:
|
The etc/sonar.sh will try to remove the file it created before it exit. .gitignore was also updated to ignore the mark file
Let me know if I can make the change across the other repositories |
Fixes #11 - Update sonar.sh to fail if rhc port-forward fails
Go for it. Should be an exact copy of this script (plus .gitignore updates) right? |
More info #11