From 0e55c562bf9832fcfbb8b078c8e331b18af34577 Mon Sep 17 00:00:00 2001 From: Eric Hameleers Date: Mon, 3 Jul 2023 19:24:04 +0000 Subject: docker: update to 24.0.2 --- docker/build/docker.SlackBuild | 123 ++++++++--------------------------------- 1 file changed, 22 insertions(+), 101 deletions(-) (limited to 'docker') diff --git a/docker/build/docker.SlackBuild b/docker/build/docker.SlackBuild index 26ee482f..13ebc12d 100755 --- a/docker/build/docker.SlackBuild +++ b/docker/build/docker.SlackBuild @@ -2,7 +2,7 @@ # $Id$ # Copyright 2014-2015 Vincent Batts # Copyright 2017-2021 Audrius Kazukauskas -# Copyright 2022 Eric Hameleers, Eindhoven, NL +# Copyright 2022, 2023 Eric Hameleers, Eindhoven, NL # All rights reserved. # # Permission to use, copy, modify, and distribute this software for @@ -30,7 +30,7 @@ # For: docker # Descr: manager for applications in Linux containers # URL: https://www.docker.com/ -# Build needs: go-md2man, google-go-lang >= 1.19 +# Build needs: go-md2man, google-go-lang >= 1.20 # Needs: containerd, runc # Changelog: # 20.10.12-1: 06/jan/2022 by Eric Hameleers @@ -43,6 +43,8 @@ # * Update. # 20.10.18-1: 12/oct/2022 by Eric Hameleers # * Update. Added docker-scan. +# 24.0.2-1: 03/jul/2023 by Eric Hameleers +# * Update. Added docker-scan. # # Run 'sh docker.SlackBuild' to build a Slackware package. # The package (.t?z) and .txt file as well as build logs are created in /tmp . @@ -51,22 +53,21 @@ # ----------------------------------------------------------------------------- PRGNAM=docker -VERSION=${VERSION:-20.10.18} +VERSION=${VERSION:-24.0.2} BUILD=${BUILD:-1} NUMJOBS=${NUMJOBS:-" -j$(nproc) "} TAG=${TAG:-alien} # Additional software bundled into the docker package (following Arch Linux): -BUILDX=${BUILDX:-0.9.1} -CLI=${CLI:-20.10.18} -LNW=${LNW:-0dde5c8.git} # the follow-up commit merges libnetwork into moby. -SCANCLI=${SCANCLI:-0.21.0} +BUILDX=${BUILDX:-0.11.0} +CLI=${CLI:-24.0.2} +SCANCLI=${SCANCLI:-0.26.0} TINI=${TINI:-0.19.0} # Git commit hashes we need to provide - check the 'tags' page of the # respective github pages for these and use the hash which belongs to the tag: -BUILDX_COMMIT=ed00243 # version 0.9.1 commit hash -MOBY_COMMIT=e42327a # version 20.10.18 commit hash +BUILDX_COMMIT=687feca # version 0.11.0 commit hash +MOBY_COMMIT=659604f # version 24.0.2 commit hash TINI_COMMIT=de40ad0 # version 0.19.0 commit hash # Where do we look for sources? @@ -75,7 +76,6 @@ SRCDIR=$(cd $(dirname $0); pwd) DOCS="$SRCDIR/README.Slackware *.md AUTHORS Dockerfile* LICENSE MAINTAINERS NOTICE" DOCS_BUILDX="AUTHORS Dockerfile LICENSE MAINTAINERS README.md" DOCS_CLI="*.md AUTHORS Dockerfile LICENSE MAINTAINERS NOTICE VERSION" -DOCS_LNW="*.md LICENSE MAINTAINERS" DOCS_SCANCLI="*.md Dockerfile LICENSE MAINTAINERS NOTICE" DOCS_TINI="*.md Dockerfile LICENSE" @@ -93,77 +93,14 @@ SRCURL[0]="https://github.com/moby/moby/archive/v${VERSION}/moby-${VERSION}.tar. SOURCE[1]="$SRCDIR/sources/cli-${CLI}.tar.gz" SRCURL[1]="https://github.com/docker/cli/archive/v${CLI}/cli-${CLI}.tar.gz" -SOURCE[2]="$SRCDIR/sources/libnetwork-${LNW}.tar.gz" -#SRCURL[2]="https://github.com/moby/libnetwork/archive/v${LNW}/libnetwork-${LNW}.tar.gz" -SRCURL[2]="" - -SOURCE[3]="$SRCDIR/sources/tini-${TINI}.tar.gz" -SRCURL[3]="https://github.com/krallin/tini/archive/v${TINI}/tini-${TINI}.tar.gz" - -SOURCE[4]="$SRCDIR/sources/buildx-${BUILDX}.tar.gz" -SRCURL[4]="https://github.com/docker/buildx/archive/v${BUILDX}/buildx-${BUILDX}.tar.gz" - -SOURCE[5]="$SRCDIR/sources/scan-cli-plugin-${SCANCLI}.tar.gz" -SRCURL[5]="https://github.com/docker/scan-cli-plugin/archive/refs/tags/v${SCANCLI}.tar.gz" - -# Use the src_checkout() function if no downloadable tarball exists. -src_checkout() { - # Param #1 : index in the SOURCE[] array. - # Param #2 : full path to where SOURCE[$1] tarball should be created. - # Determine the tarball extension: - PEXT=$(echo "${2}" | sed -r -e 's/.*[^.].(tar.xz|tar.gz|tar.bz2|tgz).*/\1/') - case "$PEXT" in - "tar.xz") TARCOMP="J" ;; - "tar.gz") TARCOMP="z" ;; - "tgz") TARCOMP="z" ;; - "tar.bz2") TARCOMP="j" ;; - *) echo "Archive can only have extension 'tar.xz', '.tar.gz' '.tar.bz2' or '.tgz'" ; exit 1 ;; - esac - # Determine the directory name to create for the archive root: - PBASE=$(basename ${2} .${PEXT}) - # Determine the directory where we create our checkout: - CODIR=$(dirname ${2}) - case ${1} in - 2) # GIT checkout: - GITURI="https://github.com/moby/libnetwork.git" - BRANCH="master" - RETDIR=$(pwd) - mkdir -p $CODIR/${PRGNAM}_temp_checkout_$$ \ - && cd $CODIR/${PRGNAM}_temp_checkout_$$ - mkdir ${PBASE} \ - && cd ${PBASE} \ - && \ - if [ "$LNW" = "HEAD" -o "$LNW" = "master" ]; then - # Checkout without downloading version history (fast!): - echo "Checking out HEAD from '$GITURI':" - # If LNW was "HEAD" we still want a date to appear in the pkgname: - LNW=$(date +%Y%m%d) - git clone --depth=1 ${GITURI} . - elif [ "${LNW#*.}" = "git" ]; then - # Checkout specific commit, version is something like '64b7a45.git': - COMMIT="${LNW%%.git}" - echo "Checking out commit '$COMMIT' from '$GITURI':" - git clone ${GITURI} . \ - && git checkout $BRANCH \ - && git checkout ${COMMIT} - else - # Checkout code from a certain branch and/or date; this will take a - # long time because we have to clone the complete git-repository first: - echo "Checking out $BRANCH at date $LNW from '$GITURI':" - git clone ${GITURI} . \ - && git checkout $BRANCH \ - && git checkout $(git rev-list -n 1 --before="$(date -d $LNW)" $BRANCH) - fi \ - && chown -R root:root . \ - && cd .. \ - && tar --exclude .git -${TARCOMP}cf ${2} ${PBASE} - cd $RETDIR - rm -rf $CODIR/${PRGNAM}_temp_checkout_$$ || true - ;; - *) # Do nothing - ;; - esac -} +SOURCE[2]="$SRCDIR/sources/tini-${TINI}.tar.gz" +SRCURL[2]="https://github.com/krallin/tini/archive/v${TINI}/tini-${TINI}.tar.gz" + +SOURCE[3]="$SRCDIR/sources/buildx-${BUILDX}.tar.gz" +SRCURL[3]="https://github.com/docker/buildx/archive/v${BUILDX}/buildx-${BUILDX}.tar.gz" + +SOURCE[4]="$SRCDIR/sources/scan-cli-plugin-${SCANCLI}.tar.gz" +SRCURL[4]="https://github.com/docker/scan-cli-plugin/archive/refs/tags/v${SCANCLI}.tar.gz" ## ## --- with a little luck, you won't have to edit below this point --- ## @@ -235,11 +172,6 @@ for (( i = 0; i < ${#SOURCE[*]}; i++ )) ; do mv -f "${SOURCE[$i]}" "${SOURCE[$i]}".FAIL exit 1 fi - else - # Try if we have a SVN/CVS download routine for ${SOURCE[$i]} - echo "Will checkout sources to $(dirname $SOURCE[$i])" - src_checkout $i "${SOURCE[$i]}" \ - 2>&1 > $OUTPUT/checkout-$(basename ${SOURCE[$i]}).log fi if [ ! -f "${SOURCE[$i]}" -o ! -s "${SOURCE[$i]}" ]; then echo "File '$(basename ${SOURCE[$i]})' not available. Aborting the build." @@ -295,8 +227,8 @@ cd $GOPATH/src/github.com/docker/cli cd - 1>/dev/null -# Compile docker daemon: -echo "-- docker daemon" +# Compile docker daemon and proxy: +echo "-- docker daemon and proxy" rm -rf $GOPATH/src mkdir -p $GOPATH/src/github.com/docker/ ln -rs moby-$VERSION $GOPATH/src/github.com/docker/docker @@ -308,16 +240,6 @@ cd $GOPATH/src/github.com/docker/docker 2>&1 | tee $OUTPUT/make-${PRGNAM}_moby.log cd - 1>/dev/null -# Compile docker-proxy: -echo "-- docker-proxy" -rm -rf $GOPATH/src -mkdir -p $GOPATH/src/github.com/docker/ -ln -rs libnetwork-$LNW $GOPATH/src/github.com/docker/libnetwork -cd $GOPATH/src/github.com/docker/libnetwork - go build github.com/docker/libnetwork/cmd/proxy \ - 2>&1 | tee $OUTPUT/make-${PRGNAM}_libnetwork.log -cd - 1>/dev/null - # Compile docker-init: echo "-- docker-init" rm -rf $GOPATH/src @@ -357,12 +279,12 @@ cd $GOPATH/src/github.com/docker/scan-cli-plugin cd - 1>/dev/null # Now install the lot: -# docker-proxy: -install -D -m0755 libnetwork-$LNW/proxy $PKG/usr/bin/docker-proxy # docker-init install -D -m0755 tini-$TINI/tini-static $PKG/usr/bin/docker-init # dockerd: install -D -m0755 moby-$VERSION/bundles/dynbinary-daemon/dockerd $PKG/usr/bin/dockerd +# docker-proxy: +install -D -m0755 moby-$VERSION/bundles/dynbinary-daemon/docker-proxy $PKG/usr/bin/docker-proxy # udev rules: install -D -m0644 moby-$VERSION/contrib/udev/80-docker.rules $PKG/usr/lib/udev/rules.d/80-docker.rules # docker-cli: @@ -402,7 +324,6 @@ mkdir -p $PKG/usr/doc/$PRGNAM-$VERSION/{buildx,cli,libnetwork,scan-cli-plugin,ti ( cd moby-$VERSION ; cp -a $DOCS $PKG/usr/doc/$PRGNAM-$VERSION ) ( cd buildx-$BUILDX ; cp -a $DOCS_BUILDX $PKG/usr/doc/$PRGNAM-$VERSION/buildx ) ( cd cli-$CLI ; cp -a $DOCS_CLI $PKG/usr/doc/$PRGNAM-$VERSION/cli ) -( cd libnetwork-$LNW ; cp -a $DOCS_LNW $PKG/usr/doc/$PRGNAM-$VERSION/libnetwork) ( cd scan-cli-plugin-$SCANCLI ; cp -a $DOCS_SCANCLI $PKG/usr/doc/$PRGNAM-$VERSION/scan-cli-plugin) ( cd tini-$TINI ; cp -a $DOCS_TINI $PKG/usr/doc/$PRGNAM-$VERSION/tini ) cat $SRCDIR/$(basename $0) > $PKG/usr/doc/$PRGNAM-$VERSION/$PRGNAM.SlackBuild -- cgit v1.2.3