@@ -421,7 +421,7 @@ pipeline {
421421 }
422422 steps {
423423 echo " Running on node: ${ NODE_NAME} "
424- sh " docker build \
424+ sh " docker buildx build \
425425 --label \" org.opencontainers.image.created=${ GITHUB_DATE} \" \
426426 --label \" org.opencontainers.image.authors=linuxserver.io\" \
427427 --label \" org.opencontainers.image.url=https://github.com/linuxserver/docker-baseimage-rdesktop-web/packages\" \
@@ -434,7 +434,7 @@ pipeline {
434434 --label \" org.opencontainers.image.ref.name=${ COMMIT_SHA} \" \
435435 --label \" org.opencontainers.image.title=Baseimage-rdesktop-web\" \
436436 --label \" org.opencontainers.image.description=baseimage-rdesktop-web image by linuxserver.io\" \
437- --no-cache --pull -t ${ IMAGE} :${ META_TAG} \
437+ --no-cache --pull -t ${ IMAGE} :${ META_TAG} --platform=linux/amd64 \
438438 --build-arg ${ BUILD_VERSION_ARG} =${ EXT_RELEASE} --build-arg VERSION=\" ${ VERSION_TAG} \" --build-arg BUILD_DATE=${ GITHUB_DATE} ."
439439 }
440440 }
@@ -451,7 +451,7 @@ pipeline {
451451 stage(' Build X86' ) {
452452 steps {
453453 echo " Running on node: ${ NODE_NAME} "
454- sh " docker build \
454+ sh " docker buildx build \
455455 --label \" org.opencontainers.image.created=${ GITHUB_DATE} \" \
456456 --label \" org.opencontainers.image.authors=linuxserver.io\" \
457457 --label \" org.opencontainers.image.url=https://github.com/linuxserver/docker-baseimage-rdesktop-web/packages\" \
@@ -464,7 +464,7 @@ pipeline {
464464 --label \" org.opencontainers.image.ref.name=${ COMMIT_SHA} \" \
465465 --label \" org.opencontainers.image.title=Baseimage-rdesktop-web\" \
466466 --label \" org.opencontainers.image.description=baseimage-rdesktop-web image by linuxserver.io\" \
467- --no-cache --pull -t ${ IMAGE} :amd64-${ META_TAG} \
467+ --no-cache --pull -t ${ IMAGE} :amd64-${ META_TAG} --platform=linux/amd64 \
468468 --build-arg ${ BUILD_VERSION_ARG} =${ EXT_RELEASE} --build-arg VERSION=\" ${ VERSION_TAG} \" --build-arg BUILD_DATE=${ GITHUB_DATE} ."
469469 }
470470 }
@@ -478,7 +478,7 @@ pipeline {
478478 sh ''' #! /bin/bash
479479 echo $GITHUB_TOKEN | docker login ghcr.io -u LinuxServer-CI --password-stdin
480480 '''
481- sh " docker build \
481+ sh " docker buildx build \
482482 --label \" org.opencontainers.image.created=${ GITHUB_DATE} \" \
483483 --label \" org.opencontainers.image.authors=linuxserver.io\" \
484484 --label \" org.opencontainers.image.url=https://github.com/linuxserver/docker-baseimage-rdesktop-web/packages\" \
@@ -491,7 +491,7 @@ pipeline {
491491 --label \" org.opencontainers.image.ref.name=${ COMMIT_SHA} \" \
492492 --label \" org.opencontainers.image.title=Baseimage-rdesktop-web\" \
493493 --label \" org.opencontainers.image.description=baseimage-rdesktop-web image by linuxserver.io\" \
494- --no-cache --pull -f Dockerfile.armhf -t ${ IMAGE} :arm32v7-${ META_TAG} \
494+ --no-cache --pull -f Dockerfile.armhf -t ${ IMAGE} :arm32v7-${ META_TAG} --platform=linux/arm/v7 \
495495 --build-arg ${ BUILD_VERSION_ARG} =${ EXT_RELEASE} --build-arg VERSION=\" ${ VERSION_TAG} \" --build-arg BUILD_DATE=${ GITHUB_DATE} ."
496496 sh " docker tag ${ IMAGE} :arm32v7-${ META_TAG} ghcr.io/linuxserver/lsiodev-buildcache:arm32v7-${ COMMIT_SHA} -${ BUILD_NUMBER} "
497497 retry(5 ) {
@@ -512,7 +512,7 @@ pipeline {
512512 sh ''' #! /bin/bash
513513 echo $GITHUB_TOKEN | docker login ghcr.io -u LinuxServer-CI --password-stdin
514514 '''
515- sh " docker build \
515+ sh " docker buildx build \
516516 --label \" org.opencontainers.image.created=${ GITHUB_DATE} \" \
517517 --label \" org.opencontainers.image.authors=linuxserver.io\" \
518518 --label \" org.opencontainers.image.url=https://github.com/linuxserver/docker-baseimage-rdesktop-web/packages\" \
@@ -525,7 +525,7 @@ pipeline {
525525 --label \" org.opencontainers.image.ref.name=${ COMMIT_SHA} \" \
526526 --label \" org.opencontainers.image.title=Baseimage-rdesktop-web\" \
527527 --label \" org.opencontainers.image.description=baseimage-rdesktop-web image by linuxserver.io\" \
528- --no-cache --pull -f Dockerfile.aarch64 -t ${ IMAGE} :arm64v8-${ META_TAG} \
528+ --no-cache --pull -f Dockerfile.aarch64 -t ${ IMAGE} :arm64v8-${ META_TAG} --platform=linux/arm64 \
529529 --build-arg ${ BUILD_VERSION_ARG} =${ EXT_RELEASE} --build-arg VERSION=\" ${ VERSION_TAG} \" --build-arg BUILD_DATE=${ GITHUB_DATE} ."
530530 sh " docker tag ${ IMAGE} :arm64v8-${ META_TAG} ghcr.io/linuxserver/lsiodev-buildcache:arm64v8-${ COMMIT_SHA} -${ BUILD_NUMBER} "
531531 retry(5 ) {
@@ -554,26 +554,12 @@ pipeline {
554554 else
555555 LOCAL_CONTAINER=${IMAGE}:${META_TAG}
556556 fi
557- if [ "${DIST_IMAGE}" == "alpine" ]; then
558- docker run --rm --entrypoint '/bin/sh' -v ${TEMPDIR}:/tmp ${LOCAL_CONTAINER} -c '\
559- apk info -v > /tmp/package_versions.txt && \
560- sort -o /tmp/package_versions.txt /tmp/package_versions.txt && \
561- chmod 777 /tmp/package_versions.txt'
562- elif [ "${DIST_IMAGE}" == "ubuntu" ]; then
563- docker run --rm --entrypoint '/bin/sh' -v ${TEMPDIR}:/tmp ${LOCAL_CONTAINER} -c '\
564- apt list -qq --installed | sed "s#/.*now ##g" | cut -d" " -f1 > /tmp/package_versions.txt && \
565- sort -o /tmp/package_versions.txt /tmp/package_versions.txt && \
566- chmod 777 /tmp/package_versions.txt'
567- elif [ "${DIST_IMAGE}" == "fedora" ]; then
568- docker run --rm --entrypoint '/bin/sh' -v ${TEMPDIR}:/tmp ${LOCAL_CONTAINER} -c '\
569- rpm -qa > /tmp/package_versions.txt && \
570- sort -o /tmp/package_versions.txt /tmp/package_versions.txt && \
571- chmod 777 /tmp/package_versions.txt'
572- elif [ "${DIST_IMAGE}" == "arch" ]; then
573- docker run --rm --entrypoint '/bin/sh' -v ${TEMPDIR}:/tmp ${LOCAL_CONTAINER} -c '\
574- pacman -Q > /tmp/package_versions.txt && \
575- chmod 777 /tmp/package_versions.txt'
576- fi
557+ touch ${TEMPDIR}/package_versions.txt
558+ docker run --rm \
559+ -v /var/run/docker.sock:/var/run/docker.sock:ro \
560+ -v ${TEMPDIR}:/tmp \
561+ ghcr.io/anchore/syft:latest \
562+ ${LOCAL_CONTAINER} -o table=/tmp/package_versions.txt
577563 NEW_PACKAGE_TAG=$(md5sum ${TEMPDIR}/package_versions.txt | cut -c1-8 )
578564 echo "Package tag sha from current packages in buit container is ${NEW_PACKAGE_TAG} comparing to old ${PACKAGE_TAG} from github"
579565 if [ "${NEW_PACKAGE_TAG}" != "${PACKAGE_TAG}" ]; then
0 commit comments