github.com/Heebron/moby@v0.0.0-20221111184709-6eab4f55faf7/hack/dockerfile/install/runc.installer (about) 1 #!/bin/sh 2 set -e 3 4 # RUNC_VERSION specifies the version of runc to install from the 5 # https://github.com/opencontainers/runc repository. 6 # 7 # The version of runc should match the version that is used by the containerd 8 # version that is used. If you need to update runc, open a pull request in 9 # the containerd project first, and update both after that is merged. 10 # 11 # When updating RUNC_VERSION, consider updating runc in vendor.mod accordingly 12 : "${RUNC_VERSION:=v1.1.4}" 13 14 install_runc() { 15 RUNC_BUILDTAGS="${RUNC_BUILDTAGS:-"seccomp"}" 16 17 echo "Install runc version $RUNC_VERSION (build tags: $RUNC_BUILDTAGS)" 18 git clone https://github.com/opencontainers/runc.git "$GOPATH/src/github.com/opencontainers/runc" 19 cd "$GOPATH/src/github.com/opencontainers/runc" 20 git checkout -q "$RUNC_VERSION" 21 if [ -z "$1" ]; then 22 target=static 23 else 24 target="$1" 25 fi 26 make BUILDTAGS="$RUNC_BUILDTAGS" "$target" 27 mkdir -p "${PREFIX}" 28 cp runc "${PREFIX}/runc" 29 }