-
Notifications
You must be signed in to change notification settings - Fork 19
/
Copy path.travis.yml
46 lines (46 loc) · 1.65 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
---
language: go
go:
- 1.15
before_install:
- go get -u golang.org/x/lint/golint
- go get -u golang.org/x/tools/cmd/goimports
- go get -u github.com/jgautheron/usedexports
- go get -u github.com/kisielk/errcheck
- go get -u github.com/rs/cors
- go get -u github.com/json-iterator/go
- go get -u github.com/google/go-github/github
# - go get -u github.com/jgautheron/goconst/cmd/goconst
# - go get -u github.com/lib/pq
# - go get -u golang.org/x/oauth2
# - go get -u golang.org/x/text/transform
# - go get -u golang.org/x/text/unicode/norm
# - go get -u gopkg.in/yaml.v2
# - go get -u github.com/mattn/go-sqlite3
- sudo -u postgres createdb gha
- sudo -u postgres psql gha -c "create user gha_admin with password 'pwd'"
- sudo -u postgres psql gha -c 'grant all privileges on database "gha" to gha_admin'
- sudo -u postgres psql gha -c "alter user gha_admin createdb"
- sudo -u postgres psql gha -c "create user ro_user with password 'pwd'"
- sudo -u postgres psql gha -c 'grant all privileges on database "gha" to ro_user'
- sudo -u postgres psql gha -c "create user devstats_team with password 'pwd'"
- sudo -u postgres psql gha -c 'grant all privileges on database "gha" to devstats_team'
script:
- cd /home/travis/gopath/src/github.com/cncf/devstatscode
- make
- make test
- GHA2DB_PROJECT=kubernetes GHA2DB_LOCAL=1 PG_PORT=5433 PG_PASS=pwd ./dbtest.sh
addons:
postgresql: "13"
apt:
packages:
- postgresql-13
- postgresql-client-13
env:
global:
- PGPORT=5433
notifications:
webhooks:
- https://teststats.cncf.io:2982/hook
- https://devstats.cncf.io:2982/hook
- https://devstats.cd.foundation:2982/hook