deps(opencv): pin opencv-python-headless==4.7.0.72; build(nixpacks): … #52
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: FitPose CI/CD | |
| on: | |
| push: | |
| branches: [ main, develop ] | |
| pull_request: | |
| branches: [ main ] | |
| env: | |
| REGISTRY: ghcr.io | |
| IMAGE_NAME_BACKEND: ${{ github.repository }}-backend | |
| IMAGE_NAME_FRONTEND: ${{ github.repository }}-frontend | |
| jobs: | |
| # Backend testing | |
| test-backend: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Set up Python | |
| uses: actions/setup-python@v4 | |
| with: | |
| python-version: '3.11' | |
| - name: Install dependencies | |
| run: | | |
| python -m pip install --upgrade pip | |
| pip install -r requirements.txt | |
| pip install pytest pytest-asyncio httpx | |
| - name: Run tests | |
| run: | | |
| # Run tests when they are created | |
| # pytest src/backend/tests/ | |
| echo "Tests will be added later" | |
| # Frontend testing | |
| test-frontend: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Setup Node.js | |
| uses: actions/setup-node@v4 | |
| with: | |
| node-version: '18' | |
| cache: 'npm' | |
| cache-dependency-path: src/frontend/package-lock.json | |
| - name: Install dependencies | |
| run: | | |
| cd src/frontend | |
| npm ci | |
| - name: Run linter | |
| run: | | |
| cd src/frontend | |
| npm run lint | |
| - name: Build | |
| run: | | |
| cd src/frontend | |
| npm run build | |
| # Note: Docker image build/deploy jobs were removed | |
| # because Dockerfiles are not present in the repo. | |
| # Re-enable when Dockerfiles are added. |