-
Notifications
You must be signed in to change notification settings - Fork 83
/
circle.yml
64 lines (60 loc) · 1.29 KB
/
circle.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
version: 2.0
jobs:
test:
docker:
- image: golang:1.9
working_directory: /go/src/github.com/lifei6671/go-git-webhook
steps:
- checkout
- run:
name: test
command: |
curl https://glide.sh/get | sh
glide install
go build -tags "pam"
deploy:
machine: true
steps:
- checkout
- run:
name: push to production
command: |
source ./prepare.sh
docker info
docker_build
docker_push microcoin/go-git-webhook:latest
staging:
machine: true
steps:
- checkout
- run:
name: push to staging
command: |
source ./prepare.sh
docker info
docker_build
docker_push microcoin/go-git-webhook:staging
workflows:
version: 2
build-n-deploy:
jobs:
- test:
filters:
tags:
only: /.*/
- staging:
context: org-global
requires:
- test
filters:
tags:
ignore: /^v.*/
- deploy:
context: org-global
requires:
- test
filters:
tags:
only: /^v.*/
branches:
ignore: /.*/