Add files via upload #21
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: CI | |
| on: | |
| push: | |
| branches: [main, develop, 'feature/*'] | |
| pull_request: | |
| branches: [main, develop, 'feature/*'] | |
| jobs: | |
| lint: | |
| name: Lint | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - uses: actions/setup-node@v4 | |
| with: | |
| node-version: 22 | |
| cache: npm | |
| - run: npm install | |
| - run: npm run lint | |
| type-check: | |
| name: Type Check | |
| runs-on: ubuntu-latest | |
| needs: lint | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - uses: actions/setup-node@v4 | |
| with: | |
| node-version: 22 | |
| cache: npm | |
| - run: npm install | |
| - run: npx tsc --noEmit | |
| test-frontend: | |
| name: Test Frontend | |
| runs-on: ubuntu-latest | |
| needs: lint | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - uses: actions/setup-node@v4 | |
| with: | |
| node-version: 22 | |
| cache: npm | |
| - run: npm install | |
| - run: npm run build --workspace=src/frontend | |
| test-backend: | |
| name: Test Backend | |
| runs-on: ubuntu-latest | |
| needs: lint | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - uses: actions/setup-node@v4 | |
| with: | |
| node-version: 22 | |
| cache: npm | |
| - run: npm install | |
| - run: npm run test --workspace=src/backend | |
| test-ml: | |
| name: Test ML Pipeline | |
| runs-on: ubuntu-latest | |
| needs: lint | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - uses: actions/setup-python@v5 | |
| with: | |
| python-version: '3.11' | |
| cache: pip | |
| - run: pip install -r requirements.txt | |
| - run: python -m pytest tests/ --tb=short -q --cov=src/ml --cov-report=xml | |
| - run: python -m flake8 src/ml/ --max-line-length=120 | |
| - run: python -m mypy src/ml/ --ignore-missing-imports --explicit-package-bases | |
| security: | |
| name: Security Scanning | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - uses: actions/setup-node@v4 | |
| with: | |
| node-version: 22 | |
| cache: npm | |
| - uses: actions/setup-python@v5 | |
| with: | |
| python-version: '3.11' | |
| - run: npm install | |
| - run: npm audit --audit-level=high --omit=dev | |
| - run: pip install pip-audit | |
| - run: pip-audit -r requirements.txt | |
| build: | |
| name: Build | |
| runs-on: ubuntu-latest | |
| needs: [test-frontend, test-backend, test-ml, type-check, security] | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - uses: actions/setup-node@v4 | |
| with: | |
| node-version: 22 | |
| cache: npm | |
| - run: npm install | |
| - run: npm run build |