ignore nix/clean.sh failures when in CI
Signed-off-by: Jakub Sokołowski <jakub@status.im>
This commit is contained in:
parent
2e06dd36da
commit
2b34900a9b
12
nix/build.sh
12
nix/build.sh
|
@ -6,8 +6,16 @@ set -e
|
||||||
function cleanup() {
|
function cleanup() {
|
||||||
# clear trapped signals
|
# clear trapped signals
|
||||||
trap - EXIT ERR INT QUIT
|
trap - EXIT ERR INT QUIT
|
||||||
# do the actual cleanup
|
# do the actual cleanup, ignore failure
|
||||||
./nix/clean.sh "${nixResultPath}"
|
if ./nix/clean.sh "${nixResultPath}"; then
|
||||||
|
echo "Successful cleanup!"
|
||||||
|
elif [[ -n "${JENKINS_URL}" ]]; then
|
||||||
|
# in CI removing some paths can fail due to parallel builds
|
||||||
|
echo "Ignoring cleanup failure in CI."
|
||||||
|
else
|
||||||
|
echo "Failed cleanup!"
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
}
|
}
|
||||||
|
|
||||||
trap cleanup EXIT ERR INT QUIT
|
trap cleanup EXIT ERR INT QUIT
|
||||||
|
|
Loading…
Reference in New Issue