From: beierlm Date: Tue, 19 Jan 2021 15:02:22 +0000 (-0500) Subject: Ensure clean snap X-Git-Tag: branch-sol006v331-start~75 X-Git-Url: https://osm.etsi.org/gitweb/?a=commitdiff_plain;h=a07a5abab74746876e0a2fd30838814cad6dc267;p=osm%2Fdevops.git Ensure clean snap 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 --- diff --git a/jenkins/ci-pipelines/ci_stage_2.groovy b/jenkins/ci-pipelines/ci_stage_2.groovy index aa9c906a..5cad17b0 100644 --- a/jenkins/ci-pipelines/ci_stage_2.groovy +++ b/jenkins/ci-pipelines/ci_stage_2.groovy @@ -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/"