-
Notifications
You must be signed in to change notification settings - Fork 1k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
chore(build) single-thread ci builds (#2494)
hoping for less/no cases of builds timing out with no output which may be to too many things happening in parallel that none is making progress fast enough
- Loading branch information
Showing
2 changed files
with
11 additions
and
9 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,28 +1,29 @@ | ||
#!/bin/bash | ||
# This script will build the project. | ||
|
||
GRADLE="./gradlew --no-daemon --max-workers=1" | ||
export GRADLE_OPTS="-Xmx1g -Xms1g" | ||
|
||
if [ "$TRAVIS_PULL_REQUEST" != "false" ]; then | ||
echo -e "Build Pull Request #$TRAVIS_PULL_REQUEST => Branch [$TRAVIS_BRANCH]" | ||
./gradlew -Prelease.useLastTag=true -Pskip.loadtest=true build | ||
$GRADLE -Prelease.useLastTag=true -Pskip.loadtest=true build | ||
elif [ "$TRAVIS_PULL_REQUEST" == "false" ] && [ "$TRAVIS_TAG" == "" ]; then | ||
echo -e 'Build Branch with Snapshot => Branch ['$TRAVIS_BRANCH']' | ||
./gradlew -Prelease.travisci=true -PbintrayUser="${bintrayUser}" -PbintrayKey="${bintrayKey}" -Pskip.loadtest=true -x test build snapshot --stacktrace | ||
$GRADLE -Prelease.travisci=true -PbintrayUser="${bintrayUser}" -PbintrayKey="${bintrayKey}" -Pskip.loadtest=true -x test build snapshot --stacktrace | ||
elif [ "$TRAVIS_PULL_REQUEST" == "false" ] && [ "$TRAVIS_TAG" != "" ]; then | ||
echo -e 'Build Branch for Release => Branch ['$TRAVIS_BRANCH'] Tag ['$TRAVIS_TAG']' | ||
case "$TRAVIS_TAG" in | ||
version-*) | ||
;; # Ignore Spinnaker product release tags. | ||
*-rc\.*) | ||
./gradlew -Prelease.travisci=true -Prelease.useLastTag=true -PbintrayUser="${bintrayUser}" -PbintrayKey="${bintrayKey}" -Pskip.loadtest=true -x test candidate --stacktrace | ||
$GRADLE -Prelease.travisci=true -Prelease.useLastTag=true -PbintrayUser="${bintrayUser}" -PbintrayKey="${bintrayKey}" -Pskip.loadtest=true -x test candidate --stacktrace | ||
;; | ||
*) | ||
./gradlew -Prelease.travisci=true -Prelease.useLastTag=true -PbintrayUser="${bintrayUser}" -PbintrayKey="${bintrayKey}" -Pskip.loadtest=true -x test final --stacktrace | ||
$GRADLE -Prelease.travisci=true -Prelease.useLastTag=true -PbintrayUser="${bintrayUser}" -PbintrayKey="${bintrayKey}" -Pskip.loadtest=true -x test final --stacktrace | ||
;; | ||
esac | ||
else | ||
echo -e 'WARN: Should not be here => Branch ['$TRAVIS_BRANCH'] Tag ['$TRAVIS_TAG'] Pull Request ['$TRAVIS_PULL_REQUEST']' | ||
./gradlew -Prelease.useLastTag=true -Pskip.loadtest=true build | ||
$GRADLE -Prelease.useLastTag=true -Pskip.loadtest=true build | ||
fi | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,19 +1,20 @@ | ||
#!/bin/bash | ||
# This script will build the project. | ||
|
||
GRADLE="./gradlew --no-daemon --max-workers=1" | ||
export GRADLE_OPTS="-Xmx1g -Xms1g" | ||
|
||
if [ "$TRAVIS_PULL_REQUEST" != "false" ]; then | ||
echo -e "Assemble Pull Request #$TRAVIS_PULL_REQUEST => Branch [$TRAVIS_BRANCH]" | ||
./gradlew -Pskip.loadtest=true assemble | ||
$GRADLE -Pskip.loadtest=true assemble | ||
elif [ "$TRAVIS_PULL_REQUEST" == "false" ] && [ "$TRAVIS_TAG" == "" ]; then | ||
echo -e 'Assemble Branch with Snapshot => Branch ['$TRAVIS_BRANCH']' | ||
./gradlew -Prelease.travisci=true -Pskip.loadtest=true -x test assemble | ||
$GRADLE -Prelease.travisci=true -Pskip.loadtest=true -x test assemble | ||
elif [ "$TRAVIS_PULL_REQUEST" == "false" ] && [ "$TRAVIS_TAG" != "" ]; then | ||
echo -e 'Assemble Branch for Release => Branch ['$TRAVIS_BRANCH'] Tag ['$TRAVIS_TAG']' | ||
./gradlew -Prelease.travisci=true -Prelease.useLastTag=true -Pskip.loadtest=true -x test assemble | ||
$GRADLE -Prelease.travisci=true -Prelease.useLastTag=true -Pskip.loadtest=true -x test assemble | ||
else | ||
echo -e 'WARN: Should not be here => Branch ['$TRAVIS_BRANCH'] Tag ['$TRAVIS_TAG'] Pull Request ['$TRAVIS_PULL_REQUEST']' | ||
./gradlew -Pskip.loadtest=true assemble | ||
$GRADLE -Pskip.loadtest=true assemble | ||
fi | ||
|