-
Notifications
You must be signed in to change notification settings - Fork 0
/
.travis.yml
43 lines (33 loc) · 1.05 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
dist: xenial
language: go
go:
- "1.12.x"
cache:
directories:
- $GOPATH/pkg/mod
git:
depth: 1
branches:
only:
- master
env:
- GO111MODULE=on
# In the Travis VM-based build environment, IPv6 networking is not
# enabled by default. The sysctl operations below enable IPv6.
# IPv6 is needed by some of the CoreDNS test cases.
before_install:
- cat /proc/net/if_inet6
- uname -a
- sudo bash -c 'if [ `cat /proc/net/if_inet6 | wc -l` = "0" ]; then echo "Enabling IPv6" ; sysctl net.ipv6.conf.all.disable_ipv6=0 ; sysctl net.ipv6.conf.default.disable_ipv6=0 ; sysctl net.ipv6.conf.lo.disable_ipv6=0 ; fi'
- cat /proc/net/if_inet6
- env
script:
- cd ../../ && mkdir coredns
- git clone --depth=1 --branch=master https://github.com/coredns/coredns.git coredns/coredns
- cd coredns/coredns
- sed -i '/^on:.*/i firewall:github.com/ihac/firewall/firewall' plugin.cfg
- make
- cd $GOPATH/src/github.com/ihac/firewall
- go test -race -coverprofile=coverage.txt -covermode=atomic ./...
after_success:
- bash <(curl -s https://codecov.io/bash)