Ensure clean snap 95/10195/1
authorbeierlm <mark.beierl@canonical.com>
Tue, 19 Jan 2021 15:02:22 +0000 (10:02 -0500)
committerbeierlm <mark.beierl@canonical.com>
Tue, 19 Jan 2021 15:02:22 +0000 (10:02 -0500)
Issues a snapcraft clean to make sure there is nothing
left from any prior runs of the build.

Change-Id: I42109d8b4a750c0a4732afcf127cc407e6956ec9
Signed-off-by: beierlm <mark.beierl@canonical.com>
jenkins/ci-pipelines/ci_stage_2.groovy

index aa9c906..5cad17b 100644 (file)
@@ -83,6 +83,7 @@ def ci_pipeline(mdg,url_prefix,project,branch,refspec,revision,do_stage_3,artifa
         stage('Snap build') {
             sh "docker pull snapcore/snapcraft:stable"
             sh "sudo rm -rf ${WORKSPACE}/stage/ ${WORKSPACE}/parts/ ${WORKSPACE}/prime/ ${WORKSPACE}/*.snap"
+            sh "sudo snapcraft clean --use-lxd"
             sh "snapcraft --use-lxd"
             sh "mv ${WORKSPACE}/${mdg}_*.snap ${WORKSPACE}/${mdg}.snap"
             sh "sudo rm -rf ${WORKSPACE}/stage/ ${WORKSPACE}/parts/ ${WORKSPACE}/prime/"