forked from ovasylenko/skillcrucial-react-redux-boilerplate
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.gitlab-ci.yml
37 lines (34 loc) · 855 Bytes
/
.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
variables:
REVIEW_HOST: ${CI_COMMIT_REF_SLUG}.${PROJECT_PREFIX}
DOCKER_NODE: TEST_mrtolerantru_node
stages:
- test
- run
- prod
Test:
stage: test
script:
- docker-compose -f docker/PROD.docker-compose.yml build --compress --parallel
- docker-compose -f docker/PROD.docker-compose.yml run node yarn test
- docker-compose -f docker/PROD.docker-compose.yml rm -f -s -v
tags:
- bash
only:
- merge_requests
Build&Run:
stage: run
script:
- docker-compose -f docker/PROD.docker-compose.yml -p ${CI_COMMIT_REF_SLUG}_${PROJECT_PREFIX} up -d --build
tags:
- bash
only:
- develop
- master
# Prod:
# stage: prod
# script:
# docker-compose -f docker/docker-compose-production.yml -p ${CI_COMMIT_REF_SLUG}_${PROJECT_PREFIX} up -d --build
# tags:
# - bash
# only:
# - production