@@ -81,14 +81,10 @@ pipeline {
8181 script{
8282 env. PACKAGE_TAG = sh(
8383 script : ''' #!/bin/bash
84- http_code=$(curl --write-out %{http_code} -s -o /dev/null \
85- https://raw.githubusercontent.com/${LS_USER}/${LS_REPO}/master/package_versions.txt)
86- if [[ "${http_code}" -ne 200 ]] ; then
87- echo none
84+ if [ -e package_versions.txt ] ; then
85+ cat package_versions.txt | md5sum | cut -c1-8
8886 else
89- curl -s \
90- https://raw.githubusercontent.com/${LS_USER}/${LS_REPO}/master/package_versions.txt \
91- | md5sum | cut -c1-8
87+ echo none
9288 fi''' ,
9389 returnStdout : true ). trim()
9490 }
@@ -112,7 +108,7 @@ pipeline {
112108 steps{
113109 script{
114110 env. EXT_RELEASE_CLEAN = sh(
115- script : ''' echo ${EXT_RELEASE} | sed 's/[~,%@+;:]//g' ''' ,
111+ script : ''' echo ${EXT_RELEASE} | sed 's/[~,%@+;:/ ]//g' ''' ,
116112 returnStdout : true ). trim()
117113 }
118114 }
@@ -333,7 +329,7 @@ pipeline {
333329 chmod 777 /tmp/package_versions.txt'
334330 elif [ "${DIST_IMAGE}" == "ubuntu" ]; then
335331 docker run --rm --entrypoint '/bin/sh' -v ${TEMPDIR}:/tmp ${LOCAL_CONTAINER} -c '\
336- apt -qq list --installed | awk "{print \$ 1, \$ 2}" > /tmp/package_versions.txt && \
332+ apt list -qq --installed > /tmp/package_versions.txt && \
337333 chmod 777 /tmp/package_versions.txt'
338334 fi
339335 NEW_PACKAGE_TAG=$(md5sum ${TEMPDIR}/package_versions.txt | cut -c1-8 )
0 commit comments