File tree Expand file tree Collapse file tree 2 files changed +25
-7
lines changed
Expand file tree Collapse file tree 2 files changed +25
-7
lines changed Original file line number Diff line number Diff line change 1515env :
1616 - TRAVIS_GOOS=linux TEST_RUNTIME=io.containerd.runc.v1 TRAVIS_CGO_ENABLED=1 TRAVIS_DISTRO=bionic GOPROXY=direct
1717 - TRAVIS_GOOS=linux TEST_RUNTIME=io.containerd.runc.v2 TRAVIS_CGO_ENABLED=1 TRAVIS_DISTRO=bionic TRAVIS_RELEASE=yes GOPROXY=direct
18+ - TRAVIS_GOOS=linux TEST_RUNTIME=io.containerd.runc.v2 TRAVIS_CGO_ENABLED=1 TRAVIS_DISTRO=bionic GOPROXY=direct RUNC_FLAVOR=crun
1819 - TRAVIS_GOOS=linux TEST_RUNTIME=io.containerd.runtime.v1.linux TRAVIS_CGO_ENABLED=1 TRAVIS_DISTRO=bionic GOPROXY=direct
1920 - TRAVIS_GOOS=darwin TRAVIS_CGO_ENABLED=0 GOPROXY=direct
2021
Original file line number Diff line number Diff line change 1414# See the License for the specific language governing permissions and
1515# limitations under the License.
1616
17-
1817#
1918# Builds and installs runc to /usr/local/go/bin based off
2019# the commit defined in vendor.conf
2120#
2221set -eu -o pipefail
2322
24- RUNC_COMMIT=$( grep opencontainers/runc " $GOPATH " /src/github.com/containerd/containerd/vendor.conf | awk ' {print $2}' )
25-
26- go get -d github.com/opencontainers/runc
27- cd " $GOPATH " /src/github.com/opencontainers/runc
28- git checkout $RUNC_COMMIT
29- make BUILDTAGS=' apparmor seccomp' runc install
23+ function install_runc() {
24+ RUNC_COMMIT=$( grep opencontainers/runc " $GOPATH " /src/github.com/containerd/containerd/vendor.conf | awk ' {print $2}' )
25+
26+ go get -d github.com/opencontainers/runc
27+ cd " $GOPATH " /src/github.com/opencontainers/runc
28+ git checkout $RUNC_COMMIT
29+ make BUILDTAGS=' apparmor seccomp' runc install
30+ }
31+
32+ function install_crun() {
33+ CRUN_VERSION=0.11
34+ curl -o /usr/local/sbin/runc -L https://github.com/containers/crun/releases/download/${CRUN_VERSION} /crun-${CRUN_VERSION} -static-$( uname -m)
35+ chmod +x /usr/local/sbin/runc
36+ }
37+
38+ : ${RUNC_FLAVOR=runc}
39+ case ${RUNC_FLAVOR} in
40+ runc) install_runc ;;
41+ crun) install_crun ;;
42+ * )
43+ echo >&2 " unknown runc flavor: ${RUNC_FLAVOR} "
44+ exit 1
45+ ;;
46+ esac
You can’t perform that action at this time.
0 commit comments