From: Tim Johnson Date: Thu, 25 Apr 2019 15:18:36 +0000 (-0700) Subject: Update jenkins-init script example X-Git-Tag: v0.37.0~2 X-Git-Url: https://gerrit.linuxfoundation.org/infra/gitweb?a=commitdiff_plain;h=refs%2Fchanges%2F16%2F15416%2F1;hp=f40007cae52fb529620d251af21c4db5a13a3d3d;p=releng%2Fglobal-jjb.git Update jenkins-init script example Update example jenking-init script to send stdout/stderr to a file. Change-Id: I5a91858d1724da41139255f2314c2c6f691070de Signed-off-by: Tim Johnson --- diff --git a/jenkins-init-scripts/README b/jenkins-init-scripts/README index 286b620f..edc6d28e 100644 --- a/jenkins-init-scripts/README +++ b/jenkins-init-scripts/README @@ -12,6 +12,8 @@ To use this create a Jenkins Managed File with the contents: #!/bin/bash + exec > /var/log/jenkins-init.log 2>&1 + gerrit_host=gerrit.example.org ciman_root=/opt/ciman @@ -31,3 +33,5 @@ To use this create a Jenkins Managed File with the contents: $ciman_root/global-jjb/jenkins-init-scripts/init.sh rm -rf $ciman_root + + echo "jenkins-init: Done" diff --git a/releasenotes/notes/logging-for-jenkins-init-8053fc153adfd95d.yaml b/releasenotes/notes/logging-for-jenkins-init-8053fc153adfd95d.yaml new file mode 100644 index 00000000..ed665f44 --- /dev/null +++ b/releasenotes/notes/logging-for-jenkins-init-8053fc153adfd95d.yaml @@ -0,0 +1,5 @@ +--- +other: + - | + Update example Jenkins Init Script in README to redirect all output to a + log file.