-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.gitlab-ci.yml
66 lines (57 loc) · 1.32 KB
/
.gitlab-ci.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
---
stages:
- test
- release
.test: &test_template
stage: test
services:
- apache/couchdb:2.3.1
variables:
COUCHDB_USER: admin
COUCHDB_PASSWORD: abc123
KIVIK_TEST_DSN: http://admin:abc123@apache-couchdb:5984/
before_script:
- curl --silent --fail -o /dev/null -X PUT ${KIVIK_TEST_DSN}/_users
- curl --silent --fail -o /dev/null -X PUT ${KIVIK_TEST_DSN}/_replicator
- curl --silent --fail -o /dev/null -X PUT ${KIVIK_TEST_DSN}/_global_changes
- curl --silent --fail -o /dev/null -X PUT ${KIVIK_TEST_DSN}/_node/nonode@nohost/_config/replicator/interval -d '"1000"'
script:
- go test -race ./...
lint:
stage: test
image: golangci/golangci-lint:v1.52.2
script:
- go mod download
- golangci-lint run ./...
- ./script/check-license.sh
coverage:
stage: test
image: golang:1.21
script:
- ./script/coverage.sh
go-1.20:
<<: *test_template
image: golang:1.20
go-1.21:
<<: *test_template
image: golang:1.21
go-rc:
<<: *test_template
image: golang:rc
allow_failure: true
.releaser: &release_template
image:
name: goreleaser/goreleaser:v1.18.1
entrypoint: [""]
variables:
GIT_DEPTH: 0
release-test:
<<: *release_template
script:
- goreleaser check
release:
<<: *release_template
script:
- goreleaser
only:
- /^v\d+\.\d+\.\d+/