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
|
sudo apt-get install -y jq
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if ! [ "$TRAVIS_REPO_SLUG" == "kubernetes/ingress-nginx" ];
|
if [ "$TRAVIS_REPO_SLUG" != "kubernetes/ingress-nginx" ];
|
||||||
then
|
then
|
||||||
echo "Only builds from kubernetes/ingress-nginx repository is allowed.";
|
echo "Only builds from kubernetes/ingress-nginx repository is allowed.";
|
||||||
exit 0;
|
exit 0;
|
||||||
|
@ -49,19 +49,19 @@ fi
|
||||||
|
|
||||||
SKIP_MESSAGE="Publication of docker image to quay.io registry skipped."
|
SKIP_MESSAGE="Publication of docker image to quay.io registry skipped."
|
||||||
|
|
||||||
if ! [ "$TRAVIS_EVENT_TYPE" == "api" ];
|
if [ "$TRAVIS_EVENT_TYPE" != "api" ];
|
||||||
then
|
then
|
||||||
echo "Only builds triggered from travis-ci API is allowed. $SKIP_MESSAGE";
|
echo "Only builds triggered from travis-ci API is allowed. $SKIP_MESSAGE";
|
||||||
exit 0;
|
exit 0;
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if ! [ "$TRAVIS_PULL_REQUEST" == "false" ];
|
if [ "$TRAVIS_PULL_REQUEST" != "false" ];
|
||||||
then
|
then
|
||||||
echo "This is a pull request. $SKIP_MESSAGE";
|
echo "This is a pull request. $SKIP_MESSAGE";
|
||||||
exit 0;
|
exit 0;
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if ! [ "$TRAVIS_PULL_REQUEST_BRANCH" == "master" ];
|
if [ "$TRAVIS_PULL_REQUEST_BRANCH" != "master" ];
|
||||||
then
|
then
|
||||||
echo "Only images build from master branch are allowed. $SKIP_MESSAGE";
|
echo "Only images build from master branch are allowed. $SKIP_MESSAGE";
|
||||||
exit 0;
|
exit 0;
|
||||||
|
|
|
@ -33,6 +33,7 @@ body=$(cat <<EOF
|
||||||
{
|
{
|
||||||
"request": {
|
"request": {
|
||||||
"branch": "master",
|
"branch": "master",
|
||||||
|
"message": "Publishing image for component $2 to quay.io",
|
||||||
"config": {
|
"config": {
|
||||||
"merge_mode": "deep_merge",
|
"merge_mode": "deep_merge",
|
||||||
"env": {
|
"env": {
|
||||||
|
|
Loading…
Reference in a new issue