-
Notifications
You must be signed in to change notification settings - Fork 0
47 lines (43 loc) · 1.18 KB
/
Copy pathci.yml
File metadata and controls
47 lines (43 loc) · 1.18 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
name: CI
on:
pull_request:
branches: [main]
push:
branches: [main]
workflow_dispatch:
permissions:
contents: read
concurrency:
group: ci-${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
cancel-in-progress: true
jobs:
test:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v7
- uses: actions/setup-go@v7
with:
go-version-file: backend/go.mod
cache-dependency-path: backend/go.sum
- uses: actions/setup-node@v7
with:
node-version: 22
cache: npm
cache-dependency-path: frontend/package-lock.json
- name: Backend tests
working-directory: backend
run: go test -race ./...
- name: Backend static analysis
working-directory: backend
run: go vet ./...
- name: Frontend install
working-directory: frontend
run: npm ci
- name: Frontend tests
working-directory: frontend
run: npm test -- --run
- name: Frontend build
working-directory: frontend
run: npm run build
- name: Validate Compose
run: docker compose --env-file .env.example config