-
Notifications
You must be signed in to change notification settings - Fork 0
/
.gitlab-ci.yml
55 lines (51 loc) · 1.16 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
stages:
- build
- deploy
test build job:
image: docker:latest
stage: build
only:
- develop@dtwilliams10/dtwilliams10.com
tags:
- develop
script:
- docker build -f test.Dockerfile -t dtwilliams10.com .
test deploy job:
image:
name: docker/compose:1.22.0
entrypoint: ["/bin/sh", "-c"]
stage: deploy
script:
- docker-compose -f "docker-compose.test.yml" down
- docker-compose -f "docker-compose.test.yml" up -d --build
environment:
name: staging
url: https://test.dtwilliams10.com
only:
- develop@dtwilliams10/dtwilliams10.com
tags:
- develop
prod build job:
image: docker:latest
stage: build
only:
- master@dtwilliams10/dtwilliams10.com
tags:
- production
script:
- docker build -f prod.Dockerfile -t dtwilliams10.com .
prod deploy job:
image:
name: docker/compose:1.22.0
entrypoint: ["/bin/sh", "-c"]
stage: deploy
script:
- docker-compose -f "docker-compose.prod.yml" down
- docker-compose -f "docker-compose.prod.yml" up -d --build
environment:
name: production
url: https://dtwilliams10.com
only:
- master@dtwilliams10/dtwilliams10.com
tags:
- production