@@ -419,7 +419,7 @@ pipeline {
419419 }
420420 steps {
421421 echo " Running on node: ${ NODE_NAME} "
422- sh " docker build \
422+ sh " docker buildx build \
423423 --label \" org.opencontainers.image.created=${ GITHUB_DATE} \" \
424424 --label \" org.opencontainers.image.authors=linuxserver.io\" \
425425 --label \" org.opencontainers.image.url=https://github.com/linuxserver/docker-baseimage-rdesktop-web/packages\" \
@@ -432,7 +432,7 @@ pipeline {
432432 --label \" org.opencontainers.image.ref.name=${ COMMIT_SHA} \" \
433433 --label \" org.opencontainers.image.title=Baseimage-rdesktop-web\" \
434434 --label \" org.opencontainers.image.description=baseimage-rdesktop-web image by linuxserver.io\" \
435- --no-cache --pull -t ${ IMAGE} :${ META_TAG} \
435+ --no-cache --pull -t ${ IMAGE} :${ META_TAG} --platform=linux/amd64 \
436436 --build-arg ${ BUILD_VERSION_ARG} =${ EXT_RELEASE} --build-arg VERSION=\" ${ VERSION_TAG} \" --build-arg BUILD_DATE=${ GITHUB_DATE} ."
437437 }
438438 }
@@ -449,7 +449,7 @@ pipeline {
449449 stage(' Build X86' ) {
450450 steps {
451451 echo " Running on node: ${ NODE_NAME} "
452- sh " docker build \
452+ sh " docker buildx build \
453453 --label \" org.opencontainers.image.created=${ GITHUB_DATE} \" \
454454 --label \" org.opencontainers.image.authors=linuxserver.io\" \
455455 --label \" org.opencontainers.image.url=https://github.com/linuxserver/docker-baseimage-rdesktop-web/packages\" \
@@ -462,7 +462,7 @@ pipeline {
462462 --label \" org.opencontainers.image.ref.name=${ COMMIT_SHA} \" \
463463 --label \" org.opencontainers.image.title=Baseimage-rdesktop-web\" \
464464 --label \" org.opencontainers.image.description=baseimage-rdesktop-web image by linuxserver.io\" \
465- --no-cache --pull -t ${ IMAGE} :amd64-${ META_TAG} \
465+ --no-cache --pull -t ${ IMAGE} :amd64-${ META_TAG} --platform=linux/amd64 \
466466 --build-arg ${ BUILD_VERSION_ARG} =${ EXT_RELEASE} --build-arg VERSION=\" ${ VERSION_TAG} \" --build-arg BUILD_DATE=${ GITHUB_DATE} ."
467467 }
468468 }
@@ -476,7 +476,7 @@ pipeline {
476476 sh ''' #! /bin/bash
477477 echo $GITHUB_TOKEN | docker login ghcr.io -u LinuxServer-CI --password-stdin
478478 '''
479- sh " docker build \
479+ sh " docker buildx build \
480480 --label \" org.opencontainers.image.created=${ GITHUB_DATE} \" \
481481 --label \" org.opencontainers.image.authors=linuxserver.io\" \
482482 --label \" org.opencontainers.image.url=https://github.com/linuxserver/docker-baseimage-rdesktop-web/packages\" \
@@ -489,7 +489,7 @@ pipeline {
489489 --label \" org.opencontainers.image.ref.name=${ COMMIT_SHA} \" \
490490 --label \" org.opencontainers.image.title=Baseimage-rdesktop-web\" \
491491 --label \" org.opencontainers.image.description=baseimage-rdesktop-web image by linuxserver.io\" \
492- --no-cache --pull -f Dockerfile.armhf -t ${ IMAGE} :arm32v7-${ META_TAG} \
492+ --no-cache --pull -f Dockerfile.armhf -t ${ IMAGE} :arm32v7-${ META_TAG} --platform=linux/arm/v7 \
493493 --build-arg ${ BUILD_VERSION_ARG} =${ EXT_RELEASE} --build-arg VERSION=\" ${ VERSION_TAG} \" --build-arg BUILD_DATE=${ GITHUB_DATE} ."
494494 sh " docker tag ${ IMAGE} :arm32v7-${ META_TAG} ghcr.io/linuxserver/lsiodev-buildcache:arm32v7-${ COMMIT_SHA} -${ BUILD_NUMBER} "
495495 retry(5 ) {
@@ -510,7 +510,7 @@ pipeline {
510510 sh ''' #! /bin/bash
511511 echo $GITHUB_TOKEN | docker login ghcr.io -u LinuxServer-CI --password-stdin
512512 '''
513- sh " docker build \
513+ sh " docker buildx build \
514514 --label \" org.opencontainers.image.created=${ GITHUB_DATE} \" \
515515 --label \" org.opencontainers.image.authors=linuxserver.io\" \
516516 --label \" org.opencontainers.image.url=https://github.com/linuxserver/docker-baseimage-rdesktop-web/packages\" \
@@ -523,7 +523,7 @@ pipeline {
523523 --label \" org.opencontainers.image.ref.name=${ COMMIT_SHA} \" \
524524 --label \" org.opencontainers.image.title=Baseimage-rdesktop-web\" \
525525 --label \" org.opencontainers.image.description=baseimage-rdesktop-web image by linuxserver.io\" \
526- --no-cache --pull -f Dockerfile.aarch64 -t ${ IMAGE} :arm64v8-${ META_TAG} \
526+ --no-cache --pull -f Dockerfile.aarch64 -t ${ IMAGE} :arm64v8-${ META_TAG} --platform=linux/arm64 \
527527 --build-arg ${ BUILD_VERSION_ARG} =${ EXT_RELEASE} --build-arg VERSION=\" ${ VERSION_TAG} \" --build-arg BUILD_DATE=${ GITHUB_DATE} ."
528528 sh " docker tag ${ IMAGE} :arm64v8-${ META_TAG} ghcr.io/linuxserver/lsiodev-buildcache:arm64v8-${ COMMIT_SHA} -${ BUILD_NUMBER} "
529529 retry(5 ) {
@@ -552,26 +552,12 @@ pipeline {
552552 else
553553 LOCAL_CONTAINER=${IMAGE}:${META_TAG}
554554 fi
555- if [ "${DIST_IMAGE}" == "alpine" ]; then
556- docker run --rm --entrypoint '/bin/sh' -v ${TEMPDIR}:/tmp ${LOCAL_CONTAINER} -c '\
557- apk info -v > /tmp/package_versions.txt && \
558- sort -o /tmp/package_versions.txt /tmp/package_versions.txt && \
559- chmod 777 /tmp/package_versions.txt'
560- elif [ "${DIST_IMAGE}" == "ubuntu" ]; then
561- docker run --rm --entrypoint '/bin/sh' -v ${TEMPDIR}:/tmp ${LOCAL_CONTAINER} -c '\
562- apt list -qq --installed | sed "s#/.*now ##g" | cut -d" " -f1 > /tmp/package_versions.txt && \
563- sort -o /tmp/package_versions.txt /tmp/package_versions.txt && \
564- chmod 777 /tmp/package_versions.txt'
565- elif [ "${DIST_IMAGE}" == "fedora" ]; then
566- docker run --rm --entrypoint '/bin/sh' -v ${TEMPDIR}:/tmp ${LOCAL_CONTAINER} -c '\
567- rpm -qa > /tmp/package_versions.txt && \
568- sort -o /tmp/package_versions.txt /tmp/package_versions.txt && \
569- chmod 777 /tmp/package_versions.txt'
570- elif [ "${DIST_IMAGE}" == "arch" ]; then
571- docker run --rm --entrypoint '/bin/sh' -v ${TEMPDIR}:/tmp ${LOCAL_CONTAINER} -c '\
572- pacman -Q > /tmp/package_versions.txt && \
573- chmod 777 /tmp/package_versions.txt'
574- fi
555+ touch ${TEMPDIR}/package_versions.txt
556+ docker run --rm \
557+ -v /var/run/docker.sock:/var/run/docker.sock:ro \
558+ -v ${TEMPDIR}:/tmp \
559+ ghcr.io/anchore/syft:latest \
560+ ${LOCAL_CONTAINER} -o table=/tmp/package_versions.txt
575561 NEW_PACKAGE_TAG=$(md5sum ${TEMPDIR}/package_versions.txt | cut -c1-8 )
576562 echo "Package tag sha from current packages in buit container is ${NEW_PACKAGE_TAG} comparing to old ${PACKAGE_TAG} from github"
577563 if [ "${NEW_PACKAGE_TAG}" != "${PACKAGE_TAG}" ]; then
0 commit comments