This repository has been archived by the owner on Dec 11, 2020. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 91
/
.travis.yml
110 lines (98 loc) · 3.11 KB
/
.travis.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
language: go
install:
# This script is used by the Travis build to install a cookie for
# go.googlesource.com so rate limits are higher when using `go get` to fetch
# packages that live there.
# See: https://github.com/golang/go/issues/12933
- bash scripts/gogetcookie.sh
env:
- GOPROXY=https://gocenter.io,https://proxy.golang.org,direct
branches:
only:
- master
matrix:
fast_finish: true
allow_failures:
- go: tip
- os: osx
- os: windows
include:
####################################
# Acceptance tests
####################################
- os: linux
name: "Acceptance tests"
dist: bionic
go: "1.15.x"
services:
- docker
sudo: required
before_install:
# locally: docker run -it ubuntu:bionic bash (https://ubuntu.pkgs.org/18.04/docker-ce-stable-amd64/)
- sudo apt-get update
- sudo apt-get -y install apt-transport-https ca-certificates curl gnupg-agent software-properties-common
- curl -fsSL https://download.docker.com/linux/ubuntu/gpg | sudo apt-key add -
- sudo add-apt-repository "deb [arch=amd64] https://download.docker.com/linux/ubuntu $(lsb_release -cs) stable"
- sudo apt-get update
# apt-cache policy docker-ce
- sudo apt-get -y install docker-ce=5:19.03.5~3-0~ubuntu-bionic
- docker version
# Allow local registry to be insecure
- sudo sed 's/DOCKER_OPTS="/DOCKER_OPTS="--insecure-registry=127.0.0.1:15000 /g' -i /etc/default/docker
- sudo cat /etc/default/docker
- sudo service docker restart
script:
- make testacc
# https://golang.org/doc/devel/release.html#policy
- os: linux
name: "Build (golang current amd64)"
dist: bionic
go: "1.15.x"
script:
- make compile
- os: linux
name: "Build (golang previous amd64)"
dist: bionic
go: "1.14.x"
script:
- make compile
####################################
# Unit, vet, website, etc
####################################
- os: linux
name: "Unit-tests, vet, and website"
dist: bionic
go: "1.15.x"
script:
- make vet
- make test
- make website-test
####################################
# Windows and Mac
####################################
- os: osx
name: "Build (golang current)"
go: "1.15.x"
script:
- XC_OS=darwin make compile
# XXX it doesn't seem possible right now to run linux containers on windows
# see: https://travis-ci.community/t/docker-linux-containers-on-windows/301
# --platform does not work, apparently missing experimental features being enabled for dockerd in the host
- os: windows
name: "Build (golang current)"
# name: "Acceptance tests"
go: "1.15.x"
# services:
# - docker
script:
- go install
# - scripts/runAccTests.bat
####################################
# Go tip
####################################
- os: linux
name: "Build (golang future amd64)"
dist: bionic
go: tip
script:
- make compile