blob: 43b55043576933d6383b582589a2193e59c358c2 [file] [log] [blame]
#!/bin/sh
# When updating RUNC_COMMIT, also update runc in vendor.conf accordingly
RUNC_COMMIT=a592beb5bc4c4092b1b1bac971afed27687340c5
install_runc() {
# Do not build with ambient capabilities support
RUNC_BUILDTAGS="${RUNC_BUILDTAGS:-"seccomp apparmor selinux"}"
echo "Install runc version $RUNC_COMMIT"
git clone https://github.com/docker/runc.git "$GOPATH/src/github.com/opencontainers/runc"
cd "$GOPATH/src/github.com/opencontainers/runc"
git checkout -q "$RUNC_COMMIT"
if [ -z "$1" ]; then
target=static
else
target="$1"
fi
# TODO: Remove me before 18.06.4
make BUILDTAGS="$RUNC_BUILDTAGS" VERSION="1.0.0-rc5+dev.docker-18.06" "$target"
mkdir -p ${PREFIX}
cp runc ${PREFIX}/docker-runc
}