Le dataset Sentiment140 reste hors git ; les tests TF/MLflow ne tournent pas encore sur le runner k3s.
30 lines
1,015 B
YAML
30 lines
1,015 B
YAML
# CI — P7 Sentiment API
|
|
# Même fichier lu par Forgejo Actions et GitHub Actions (OC-ADR-001).
|
|
# Image job = node:22-bookworm (label runner mini-pc-k3s). Pas d'image ubuntu native.
|
|
|
|
name: CI
|
|
|
|
on:
|
|
push:
|
|
branches: [main]
|
|
workflow_dispatch:
|
|
|
|
jobs:
|
|
test-preprocessing:
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- name: Checkout
|
|
uses: actions/checkout@v4
|
|
|
|
- name: Python + pytest (preprocessing only)
|
|
run: |
|
|
set -eu
|
|
apt-get update
|
|
apt-get install -y --no-install-recommends python3 python3-pip python3-venv
|
|
python3 -m pip install --break-system-packages nltk pytest
|
|
python3 -m nltk.downloader punkt punkt_tab stopwords wordnet omw-1.4
|
|
python3 -m pytest deployment/api/tests/test_preprocessing.py -q
|
|
|
|
# test_main.py charge TensorFlow + artefacts MLflow (prod). Pas dans ce job :
|
|
# trop lourd pour le runner (DinD 8 Gio) et exige des secrets MLflow.
|
|
# Build/push image : Phase 6 (dual registry), après secrets Forgejo.
|