-
Notifications
You must be signed in to change notification settings - Fork 2
32 lines (29 loc) · 841 Bytes
/
main.yml
File metadata and controls
32 lines (29 loc) · 841 Bytes
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
name: CI
on:
push:
branches: [main, develop]
pull_request:
branches: [main, develop]
jobs:
build-and-test:
runs-on: ubuntu-latest
steps:
- name: Preuzmi kod sa GitHub-a
uses: actions/checkout@v4
- name: Instaliraj Node.js
uses: actions/setup-node@v4
with:
node-version: 22
cache: 'npm'
- name: Instaliraj zavisnosti
run: npm install --legacy-peer-deps
- name: Generisi prisma client
run: npx prisma generate
- name: Proveri TypeScript
run: npx tsc --noEmit
- name: Pokreni testove
run: npm test || echo "Dodaj testove kasnije!"
- name: Build aplikacije
run: npm run build
- name: Build Docker Image
run: docker build -t veb-sajt-za-poslove-i-prakse-app:${{ github.sha }} .