forked from review-ping/coFlo
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.gitlab-ci.yml
51 lines (48 loc) · 1.14 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
stages:
- build
build_BE:
stage: build
image: gradle:8.8-jdk21
before_script:
- echo "[INFO] YML Settings"
- chmod +x backend/gradlew
script:
- cd backend
- ./gradlew clean build -x test -Dspring.profiles.active=prod
- cp build/libs/coflo-0.0.1-SNAPSHOT.jar ~/coflo/spring-docker
- sh ~/coflo/spring-docker/spring.sh
rules:
- if: '$CI_COMMIT_BRANCH == "be/dev"'
tags:
- prod
build_FE:
stage: build
image: node
before_script:
- echo "[INFO] YML Settings"
- cd frontend
- printenv | grep 'VITE_' > .env
script:
- npm install
- npm run build
- sudo cp -R dist ~/coflo/coflo-fe
- sh ~/coflo/coflo-fe/react.sh
rules:
- if: '$CI_COMMIT_BRANCH == "fe/dev"'
tags:
- prod
build_AI:
stage: build
image: gradle:8.8-jdk21
before_script:
- echo "[INFO] YML Settings"
- chmod +x ai/gradlew
script:
- cd ai
- ./gradlew clean build -x test -Dspring.profiles.active=prod
- cp build/libs/coflo-0.0.1-SNAPSHOT.jar ~/coflo/spring-docker-ai
- sh ~/coflo/spring-docker-ai/spring.sh
rules:
- if: '$CI_COMMIT_BRANCH == "ai/dev"'
tags:
- prod