Merge pull request #1595 from aledbf/improve
Improve error messages [ci skip]
This commit is contained in:
commit
73f5b9ba2f
2 changed files with 5 additions and 4 deletions
|
@ -28,7 +28,7 @@ if ! [ -x "$(command -v jq)" ]; then
|
|||
sudo apt-get install -y jq
|
||||
fi
|
||||
|
||||
if ! [ "$TRAVIS_REPO_SLUG" == "kubernetes/ingress-nginx" ];
|
||||
if [ "$TRAVIS_REPO_SLUG" != "kubernetes/ingress-nginx" ];
|
||||
then
|
||||
echo "Only builds from kubernetes/ingress-nginx repository is allowed.";
|
||||
exit 0;
|
||||
|
@ -49,19 +49,19 @@ fi
|
|||
|
||||
SKIP_MESSAGE="Publication of docker image to quay.io registry skipped."
|
||||
|
||||
if ! [ "$TRAVIS_EVENT_TYPE" == "api" ];
|
||||
if [ "$TRAVIS_EVENT_TYPE" != "api" ];
|
||||
then
|
||||
echo "Only builds triggered from travis-ci API is allowed. $SKIP_MESSAGE";
|
||||
exit 0;
|
||||
fi
|
||||
|
||||
if ! [ "$TRAVIS_PULL_REQUEST" == "false" ];
|
||||
if [ "$TRAVIS_PULL_REQUEST" != "false" ];
|
||||
then
|
||||
echo "This is a pull request. $SKIP_MESSAGE";
|
||||
exit 0;
|
||||
fi
|
||||
|
||||
if ! [ "$TRAVIS_PULL_REQUEST_BRANCH" == "master" ];
|
||||
if [ "$TRAVIS_PULL_REQUEST_BRANCH" != "master" ];
|
||||
then
|
||||
echo "Only images build from master branch are allowed. $SKIP_MESSAGE";
|
||||
exit 0;
|
||||
|
|
|
@ -33,6 +33,7 @@ body=$(cat <<EOF
|
|||
{
|
||||
"request": {
|
||||
"branch": "master",
|
||||
"message": "Publishing image for component $2 to quay.io",
|
||||
"config": {
|
||||
"merge_mode": "deep_merge",
|
||||
"env": {
|
||||
|
|
Loading…
Reference in a new issue