forked from 3liz/lizmap-web-client
-
Notifications
You must be signed in to change notification settings - Fork 1
/
.gitlab-ci.yml
183 lines (168 loc) · 2.83 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
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
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
stages:
- build
- tests
- package
- docker-image
- deploy
- release
cache:
key: "$CI_COMMIT_REF_SLUG"
paths:
- lizmap/vendor/
- assets/node_modules/
build:
stage: build
script:
- make build
environment:
name: snap
artifacts:
name: "lizmap-web-client-${CI_COMMIT_SHA}-js"
paths:
- lizmap/www/assets/js/lizmap.js
- lizmap/www/assets/js/lizmap.js.map
tags:
- fabric
tests:
stage: tests
script:
- make tests
environment:
name: snap
cache:
key: "tests-$CI_COMMIT_REF_SLUG"
paths:
- tests/units/vendor/
- tests/units/composer.lock
dependencies:
- build
tags:
- fabric
package:
stage: package
script:
- make clean ci_package saas_package
environment:
name: snap
dependencies:
- build
- tests
artifacts:
name: "lizmap-web-client-${CI_COMMIT_SHA}"
paths:
- "build/*.zip"
- "build/MANIFEST"
- "build/*.manifest"
only:
- /^release_.*$/
- master
- tags
tags:
- fabric
docker-image-unstable:
stage: docker-image
script:
- make docker-build-ci docker-deliver docker-clean
#- make docker-hub
environment:
name: snap
artifacts:
paths:
- docker/factory.manifest
dependencies:
- package
only:
- /^release_.*$/
- master
except:
- tags
tags:
- infrav3
docker-image-release:
stage: docker-image
script:
- make docker-build-ci docker-deliver docker-clean-all DO_RELEASE=y
environment:
name: snap
artifacts:
paths:
- docker/factory.manifest
dependencies:
- package
only:
- tags
tags:
- infrav3
deploy-package-unstable:
stage: deploy
script:
- make deploy_download
- make saas_deploy_snap
environment:
name: snap
dependencies:
- package
only:
- /^release_.*$/
- master
except:
- tags
tags:
- fabric
deploy-docker-unstable:
stage: deploy
script:
- $HOME/bin/lzmservicectl update -C MUTU lizmap --annotate="Updated image ($CI_COMMIT_SHORT_SHA)"
environment:
name: snap
dependencies:
- docker-image-unstable
only:
- /^release_.*$/
- master
except:
- tags
tags:
- infrav3
deploy-quick-release:
stage: release
script:
- make saas_release DO_RELEASE=y
environment:
name: production
dependencies:
- package
only:
- /^release_.*$/
tags:
- fabric
except:
- tags
when: manual
deploy-release:
stage: release
script:
- make deploy_download_stable
- make saas_release DO_RELEASE=y
environment:
name: production
dependencies:
- package
tags:
- fabric
only:
- tags
when: manual
docker-release:
stage: release
script:
- make docker-release
environment:
name: production
dependencies:
- docker-image-release
when: manual
only:
- tags
tags:
- infrav3