-
Notifications
You must be signed in to change notification settings - Fork 10
/
.alloy-ci.yml
92 lines (81 loc) · 1.55 KB
/
.alloy-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
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
image: elixir:latest
stages:
- test
- build
- deploy
services:
- postgres:9.6
cache:
paths:
- _build/
- deps/
variables:
MIX_ENV: test
GITHUB_CLIENT_ID: fake-id
GITHUB_CLIENT_SECRET: fake-secret
GITHUB_SECRET_TOKEN: fake-token
SECRET_KEY_BASE: NULr4xlNDNzEwE77UHdId7cQU+vuaPJ+Q5x3l+7dppQngBsL5EkjEaMu0S9cCGbk
DATABASE_URL: postgres://postgres@postgres:5432/alloy_ci_test
before_script:
- mix local.hex --force
- mix local.rebar --force
- mix deps.get
- mix ecto.setup
mix + coveralls:
stage: test
tags:
- elixir
- postgres
script:
- mix coveralls.post --branch "$CI_COMMIT_REF_SLUG" -n "$CI_SERVER_NAME" --sha
"$CI_COMMIT_SHA" -c "$CI_COMMIT_PUSHER" --message "$CI_COMMIT_MESSAGE"
credo + formatter:
stage: test
tags:
- elixir
script:
- mix credo
- mix format --check-formatted
.docker: &docker
image: docker:git
cache:
paths: []
before_script: []
stage: build
services:
- docker:dind
image build:
<<: *docker
variables:
TAG: test-builder
DOCKER_DRIVER: overlay
DOCKER_HOST: tcp://docker:2375
script:
- apk add --update make
- make build
only:
- branches
except:
- master
image release bleeding:
<<: *docker
variables:
TAG: bleeding
DOCKER_DRIVER: overlay
DOCKER_HOST: tcp://docker:2375
script:
- apk add --update make
- make release
only:
- master
image release:
<<: *docker
variables:
DOCKER_DRIVER: overlay
DOCKER_HOST: tcp://docker:2375
script:
- apk add --update make
- make release
- make latest
only:
- tags