-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.gitlab-ci.yml
85 lines (78 loc) · 1.77 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
stages:
- setup
- check
- build
- deploy
cache:
paths:
- node_modules/
setup:
image: registry.blitzhub.io/ng_cli_karma
stage: setup
script:
- npm install
check:lint:
image: registry.blitzhub.io/ng_cli_karma
stage: check
script:
- npm install
# - npm run lint
dependencies:
- setup
#check:test:
# image: trion/ng-cli-karma
# stage: check
# script:
# - npm install
# - ng test
# dependencies:
# - setup
build:
image: registry.blitzhub.io/ng_cli_karma
stage: build
artifacts:
paths:
- dist
script:
- npm install
- npm run build --max_old_space_size=8192 --prod
dependencies:
- check:lint
# - check:test
deploy:dev:
image: registry.blitzhub.io/docker
stage: deploy
only:
- development
services:
- name: registry.blitzhub.io/docker:dind
alias: docker
variables:
CONTAINER_HOSTNAME: docker
before_script:
- docker info
- docker login -u $CI_REGISTRY_USER -p $CI_REGISTRY_PASSWORD $CI_REGISTRY
script:
- docker build -t gitlab.rrz.uni-hamburg.de:4567/cosy-bio/drugst.one/website:dev -f ./Dockerfile .
- docker push gitlab.rrz.uni-hamburg.de:4567/cosy-bio/drugst.one/website:dev
dependencies:
- build
deploy:prod:
image: registry.blitzhub.io/docker
stage: deploy
only:
- production
when: manual
services:
- name: registry.blitzhub.io/docker:dind
alias: docker
variables:
CONTAINER_HOSTNAME: docker
before_script:
- docker info
- docker login -u $CI_REGISTRY_USER -p $CI_REGISTRY_PASSWORD $CI_REGISTRY
script:
- docker build -t gitlab.rrz.uni-hamburg.de:4567/cosy-bio/drugst.one/website:prod -f ./Dockerfile .
- docker push gitlab.rrz.uni-hamburg.de:4567/cosy-bio/drugst.one/website:prod
dependencies:
- build