This repository was archived by the owner on Apr 20, 2025. It is now read-only.
-
-
Notifications
You must be signed in to change notification settings - Fork 12
57 lines (47 loc) · 1.29 KB
/
CI-PR.yaml
File metadata and controls
57 lines (47 loc) · 1.29 KB
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
name: PR Checks 🤞🏼
on:
pull_request:
paths:
- 'src/**'
- 'build.sh'
branches: [ main ]
jobs:
golang_build:
runs-on: ubuntu-latest
environment: testing
steps:
- uses: actions/checkout@v3
- name: 🧪 backend Merger
run: |
cd src/backend/merger
docker build --target test -t xyz .
docker run --rm xyz
- name: 🧪 backend Rotator
run: |
cd src/backend/rotator
docker build --target test -t xyz .
docker run --rm xyz
npm_build:
runs-on: ubuntu-latest
environment: testing
steps:
- uses: actions/checkout@v3
- name: 🧪 frontend
run: |
cd src/frontend
docker build --target test -t xyz .
docker run --rm xyz
docker_build:
needs: [golang_build,npm_build]
runs-on: ubuntu-latest
environment: testing
steps:
- uses: actions/checkout@v3
- name: Build the Docker image
run: |
cd src/backend/merger
docker build . --target prod --file Dockerfile --tag pdf-editor:$(date +%s)-merge
cd ../rotator
docker build . --target prod --file Dockerfile --tag pdf-editor:$(date +%s)-rotate
cd ../../frontend
docker build . --target prod --file Dockerfile --tag pdf-editor:$(date +%s)-frontend