mirror of
https://github.com/Monadical-SAS/reflector.git
synced 2025-12-20 20:29:06 +00:00
* ci: use github-token to get around potential api throttling * build: put pyannote-audio separate to the project * fix: now that we have a readme, use it * build: add UV_NO_CACHE
60 lines
1.4 KiB
YAML
60 lines
1.4 KiB
YAML
name: Unittests
|
|
|
|
on:
|
|
pull_request:
|
|
paths:
|
|
- "server/**"
|
|
push:
|
|
paths:
|
|
- "server/**"
|
|
|
|
jobs:
|
|
pytest:
|
|
runs-on: ubuntu-latest
|
|
services:
|
|
redis:
|
|
image: redis:6
|
|
ports:
|
|
- 6379:6379
|
|
steps:
|
|
- uses: actions/checkout@v4
|
|
- name: Install uv
|
|
uses: astral-sh/setup-uv@v6
|
|
with:
|
|
enable-cache: true
|
|
working-directory: server
|
|
- name: Tests
|
|
run: |
|
|
cd server
|
|
uv run -m pytest -v tests
|
|
|
|
docker-amd64:
|
|
runs-on: linux-amd64
|
|
steps:
|
|
- uses: actions/checkout@v4
|
|
- name: Set up Docker Buildx
|
|
uses: docker/setup-buildx-action@v3
|
|
- name: Build AMD64
|
|
uses: docker/build-push-action@v6
|
|
with:
|
|
context: server
|
|
platforms: linux/amd64
|
|
cache-from: type=gha,scope=amd64
|
|
cache-to: type=gha,mode=max,scope=amd64
|
|
github-token: ${{ secrets.GHA_CACHE_TOKEN }}
|
|
|
|
docker-arm64:
|
|
runs-on: linux-arm64
|
|
steps:
|
|
- uses: actions/checkout@v4
|
|
- name: Set up Docker Buildx
|
|
uses: docker/setup-buildx-action@v3
|
|
- name: Build ARM64
|
|
uses: docker/build-push-action@v6
|
|
with:
|
|
context: server
|
|
platforms: linux/arm64
|
|
cache-from: type=gha,scope=arm64
|
|
cache-to: type=gha,mode=max,scope=arm64
|
|
github-token: ${{ secrets.GHA_CACHE_TOKEN }}
|