laforge has submitted this change. ( 
https://gerrit.osmocom.org/c/docker-playground/+/19429 )

Change subject: jenkins-common.sh: exit early on full disk
......................................................................

jenkins-common.sh: exit early on full disk

When my disk runs full, jenkins-common.sh fails to create a VOL_BASEDIR right
at the start, and hence no testsuite gets its external volumes mounted
properly. However, the test suite still starts up with missing cfg files etc,
and fails in non-obvious ways, until I find out the disk is full some minutes
later. Instead, verify that the base dir really exists or bail out right there.

Change-Id: I6540797c8e0ee3e7b09d4a80592d5e270e7d9adc
---
M jenkins-common.sh
1 file changed, 5 insertions(+), 0 deletions(-)

Approvals:
  laforge: Looks good to me, approved; Verified
  fixeria: Looks good to me, approved



diff --git a/jenkins-common.sh b/jenkins-common.sh
index a29720c..64ec0bb 100644
--- a/jenkins-common.sh
+++ b/jenkins-common.sh
@@ -135,6 +135,11 @@
        mkdir -p "$VOL_BASE_DIR"
 fi

+if [ ! -d "$VOL_BASE_DIR" ]; then
+       echo "ERROR: \$VOL_BASE_DIR does not exist: '$VOL_BASE_DIR'"
+       exit 1
+fi
+
 # non-jenkins execution: put logs in /tmp
 if [ "x$BUILD_TAG" = "x" ]; then
        BUILD_TAG=nonjenkins

--
To view, visit https://gerrit.osmocom.org/c/docker-playground/+/19429
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings

Gerrit-Project: docker-playground
Gerrit-Branch: master
Gerrit-Change-Id: I6540797c8e0ee3e7b09d4a80592d5e270e7d9adc
Gerrit-Change-Number: 19429
Gerrit-PatchSet: 2
Gerrit-Owner: neels <[email protected]>
Gerrit-Reviewer: fixeria <[email protected]>
Gerrit-Reviewer: laforge <[email protected]>
Gerrit-MessageType: merged

Reply via email to