ci: fix test workflow - use local Node.js
This commit is contained in:
parent
b409a22322
commit
1d169b1228
|
|
@ -3,31 +3,22 @@ name: Build Test
|
||||||
on:
|
on:
|
||||||
push:
|
push:
|
||||||
branches: [main, develop]
|
branches: [main, develop]
|
||||||
pull_request:
|
|
||||||
branches: [main]
|
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
build-frontend:
|
|
||||||
runs-on: ubuntu-latest
|
|
||||||
steps:
|
|
||||||
- uses: actions/checkout@v3
|
|
||||||
- uses: actions/setup-node@v3
|
|
||||||
with:
|
|
||||||
node-version: '20'
|
|
||||||
- name: Install & Build
|
|
||||||
working-directory: ./frontend
|
|
||||||
run: |
|
|
||||||
npm install
|
|
||||||
npm run build
|
|
||||||
- name: Check build output
|
|
||||||
run: ls -la frontend/dist/
|
|
||||||
|
|
||||||
lint-backend:
|
lint-backend:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v3
|
- name: Check backend syntax
|
||||||
- uses: actions/setup-python@v4
|
run: |
|
||||||
with:
|
python3 -m py_compile /home/lars/docker/bodytrack/backend/main.py
|
||||||
python-version: '3.12'
|
echo "✓ Backend syntax OK"
|
||||||
- name: Check syntax
|
|
||||||
run: python3 -m py_compile backend/main.py && echo "✓ Backend syntax OK"
|
build-frontend:
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
steps:
|
||||||
|
- name: Build frontend
|
||||||
|
run: |
|
||||||
|
cd /home/lars/docker/bodytrack/frontend
|
||||||
|
npm install
|
||||||
|
npm run build
|
||||||
|
echo "✓ Frontend build OK"
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue
Block a user