<p>George Joseph <strong>submitted</strong> this change.</p><p><a href="https://gerrit.asterisk.org/c/testsuite/+/13258">View Change</a></p><div style="white-space:pre-wrap">Approvals:
  George Joseph: Looks good to me, approved; Approved for Submit

</div><pre style="font-family: monospace,monospace; white-space: pre-wrap;">CI: Increase clone depth and do better cleanup<br><br>The original clone depth of 10 was causing the need to rebase<br>changes whose parent was older than the 10 commits.  The clone<br>depth has been increased to 100.<br><br>Workspace cleanup was only happening for successful builds which<br>wasn't enough to keep the 8G workspace in-memory drives on the<br>docker slaves from filling up.  Now the workspaces are cleaned up<br>after every build regardless of success/failure.  If you need to<br>preserve builds temporarily, you can log into Jenkins/Manage<br>Jenkins/Configure System and change the CLEANUP_WS_* environment<br>variable for the job type you're troubleshooting to "FALSE".<br><br>Change-Id: I8e7dc1eab8c132c0315dfecd8395a8ffa2a2e3d2<br>(cherry picked from commit d4753f771d0440e6be9b1440a563584a7d9d83f2)<br>(cherry picked from commit 77d7bb0b625945cac38f821f37cf1b5402ee9afa)<br>(cherry picked from commit c547cce6cfd958e17da58796552a388b272edaa7)<br>---<br>M CI/gates.jenkinsfile<br>M CI/unittests.jenkinsfile<br>2 files changed, 14 insertions(+), 8 deletions(-)<br><br></pre><pre style="font-family: monospace,monospace; white-space: pre-wrap;"><span>diff --git a/CI/gates.jenkinsfile b/CI/gates.jenkinsfile</span><br><span>index 309bed6..3441c00 100644</span><br><span>--- a/CI/gates.jenkinsfile</span><br><span>+++ b/CI/gates.jenkinsfile</span><br><span>@@ -107,7 +107,7 @@</span><br><span>                                                                 [$class: 'CloneOption',</span><br><span>                                                                      honorRefspec: true,</span><br><span>                                                                  noTags: true,</span><br><span style="color: hsl(0, 100%, 40%);">-                                                                   depth: 10,</span><br><span style="color: hsl(120, 100%, 40%);">+                                                                    depth: 100,</span><br><span>                                                                  shallow: true</span><br><span>                                                                ],</span><br><span>                                                           [$class: 'PruneStaleBranch'],</span><br><span>@@ -146,7 +146,7 @@</span><br><span>                                                          [$class: 'RelativeTargetDirectory', relativeTargetDir: astDir],</span><br><span>                                                              [$class: 'CloneOption',</span><br><span>                                                                      noTags: true,</span><br><span style="color: hsl(0, 100%, 40%);">-                                                                   depth: 10,</span><br><span style="color: hsl(120, 100%, 40%);">+                                                                    depth: 100,</span><br><span>                                                                  honorRefspec: true,</span><br><span>                                                                  shallow: true</span><br><span>                                                                ],</span><br><span>@@ -173,8 +173,11 @@</span><br><span>    }</span><br><span>    post {</span><br><span>               cleanup {</span><br><span style="color: hsl(0, 100%, 40%);">-                       sh "sudo make distclean 2&>/dev/null || : "</span><br><span style="color: hsl(0, 100%, 40%);">-                    sh "sudo rm -rf CI/output 2&>/dev/null || : "</span><br><span style="color: hsl(120, 100%, 40%);">+                        script {</span><br><span style="color: hsl(120, 100%, 40%);">+                              if (env.CLEANUP_WS_GATES.toBoolean()) {</span><br><span style="color: hsl(120, 100%, 40%);">+                                       cleanWs deleteDirs: true, notFailBuild: false</span><br><span style="color: hsl(120, 100%, 40%);">+                         }</span><br><span style="color: hsl(120, 100%, 40%);">+                     }</span><br><span>            }</span><br><span>            /*</span><br><span>            * The Gerrit Trigger will automatically post the "Verified" results back</span><br><span>diff --git a/CI/unittests.jenkinsfile b/CI/unittests.jenkinsfile</span><br><span>index 8eb2615..0312c24 100644</span><br><span>--- a/CI/unittests.jenkinsfile</span><br><span>+++ b/CI/unittests.jenkinsfile</span><br><span>@@ -109,7 +109,7 @@</span><br><span>                                                               [$class: 'CloneOption',</span><br><span>                                                                      honorRefspec: true,</span><br><span>                                                                  noTags: true,</span><br><span style="color: hsl(0, 100%, 40%);">-                                                                   depth: 10,</span><br><span style="color: hsl(120, 100%, 40%);">+                                                                    depth: 100,</span><br><span>                                                                  shallow: true</span><br><span>                                                                ],</span><br><span>                                                           [$class: 'PruneStaleBranch'],</span><br><span>@@ -148,7 +148,7 @@</span><br><span>                                                          [$class: 'RelativeTargetDirectory', relativeTargetDir: astDir],</span><br><span>                                                              [$class: 'CloneOption',</span><br><span>                                                                      noTags: true,</span><br><span style="color: hsl(0, 100%, 40%);">-                                                                   depth: 10,</span><br><span style="color: hsl(120, 100%, 40%);">+                                                                    depth: 100,</span><br><span>                                                                  honorRefspec: true,</span><br><span>                                                                  shallow: true</span><br><span>                                                                ],</span><br><span>@@ -175,8 +175,11 @@</span><br><span>    }</span><br><span>    post {</span><br><span>               cleanup {</span><br><span style="color: hsl(0, 100%, 40%);">-                       sh "sudo make distclean 2&>/dev/null || : "</span><br><span style="color: hsl(0, 100%, 40%);">-                    sh "sudo rm -rf CI/output 2&>/dev/null || : "</span><br><span style="color: hsl(120, 100%, 40%);">+                        script {</span><br><span style="color: hsl(120, 100%, 40%);">+                              if (env.CLEANUP_WS_UNITTESTS.toBoolean()) {</span><br><span style="color: hsl(120, 100%, 40%);">+                                   cleanWs deleteDirs: true, notFailBuild: false</span><br><span style="color: hsl(120, 100%, 40%);">+                         }</span><br><span style="color: hsl(120, 100%, 40%);">+                     }</span><br><span>            }</span><br><span>            /*</span><br><span>            * The Gerrit Trigger will automatically post the "Verified" results back</span><br><span></span><br></pre><p>To view, visit <a href="https://gerrit.asterisk.org/c/testsuite/+/13258">change 13258</a>. To unsubscribe, or for help writing mail filters, visit <a href="https://gerrit.asterisk.org/settings">settings</a>.</p><div itemscope itemtype="http://schema.org/EmailMessage"><div itemscope itemprop="action" itemtype="http://schema.org/ViewAction"><link itemprop="url" href="https://gerrit.asterisk.org/c/testsuite/+/13258"/><meta itemprop="name" content="View Change"/></div></div>

<div style="display:none"> Gerrit-Project: testsuite </div>
<div style="display:none"> Gerrit-Branch: master </div>
<div style="display:none"> Gerrit-Change-Id: I8e7dc1eab8c132c0315dfecd8395a8ffa2a2e3d2 </div>
<div style="display:none"> Gerrit-Change-Number: 13258 </div>
<div style="display:none"> Gerrit-PatchSet: 2 </div>
<div style="display:none"> Gerrit-Owner: George Joseph <gjoseph@digium.com> </div>
<div style="display:none"> Gerrit-Reviewer: Friendly Automation </div>
<div style="display:none"> Gerrit-Reviewer: George Joseph <gjoseph@digium.com> </div>
<div style="display:none"> Gerrit-Reviewer: Kevin Harwell <kharwell@digium.com> </div>
<div style="display:none"> Gerrit-MessageType: merged </div>