ci: adapt to go mod

switch go mod on explicitly in CI

travisci: enable caching of Go modules

travisci: drop obsolete hack
This commit is contained in:
Dmitry Rozhkov 2019-08-23 11:17:07 +03:00
parent 097ce827de
commit 91c890b1e1
2 changed files with 7 additions and 4 deletions

View File

@ -5,11 +5,16 @@ dist: xenial
go:
- 1.12.x
cache:
directories:
- $GOPATH/pkg/mod
env:
global:
- RUNC_VERSION=v1.0.0-rc8
- CRIO_VERSION=v1.14.6
- BUILDAH_VERSION=v1.10.0
- GO111MODULE=on
sudo: required
@ -18,9 +23,6 @@ before_install:
- go get -v golang.org/x/lint/golint
- go get -v github.com/fzipp/gocyclo
- go get -v golang.org/x/tools/go/analysis/passes/shadow/cmd/shadow
## hack for building on forks
- repo=`basename $PWD`; src=`dirname $PWD`; dest="`dirname $src`/intel"
- if [[ "$src" != "$dest" ]]; then mv "$src" "$dest"; cd ../../intel/$repo; export TRAVIS_BUILD_DIR=`dirname $TRAVIS_BUILD_DIR`/$repo; fi
## install buildah build deps
- cdir=$(pwd)
- sudo apt-get update

3
Jenkinsfile vendored
View File

@ -6,10 +6,11 @@ pipeline {
timeout(time: 2, unit: "HOURS")
}
environment {
GO111MODULE="on"
RUNC_VERSION="v1.0.0-rc8"
CRIO_VERSION="v1.14.6"
BUILDAH_VERSION="v1.10.0"
GO_VERSION="1.12.8"
GO_VERSION="1.12.9"
GO_TAR="go${GO_VERSION}.linux-amd64.tar.gz"
GOROOT="/usr/local/go"
GOPATH="/tmp/go"