Sprint 1 : scaffolding complet de Glibredecision
Plateforme de decisions collectives pour Duniter/G1. Backend FastAPI async + PostgreSQL (14 tables, 8 routers, 6 services, moteur de vote avec formule d'inertie WoT/Smith/TechComm). Frontend Nuxt 4 + Nuxt UI v3 + Pinia (9 pages, 5 stores). Infrastructure Docker + Woodpecker CI + Traefik. Documentation technique et utilisateur (15 fichiers). Seed : Licence G1, Engagement Forgeron v2.0.0, 4 protocoles de vote. 30 tests unitaires (formules, mode params, vote nuance) -- tous verts. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
75
.woodpecker.yml
Normal file
75
.woodpecker.yml
Normal file
@@ -0,0 +1,75 @@
|
||||
when:
|
||||
branch: main
|
||||
event: push
|
||||
|
||||
steps:
|
||||
test-backend:
|
||||
image: python:3.11-slim
|
||||
commands:
|
||||
- cd backend
|
||||
- pip install --no-cache-dir -r requirements.txt
|
||||
- pytest app/tests/ -v --tb=short
|
||||
|
||||
test-frontend:
|
||||
image: node:20-slim
|
||||
commands:
|
||||
- cd frontend
|
||||
- npm ci
|
||||
- npm run build
|
||||
|
||||
docker-backend:
|
||||
image: woodpeckerci/plugin-docker-buildx
|
||||
depends_on:
|
||||
- test-backend
|
||||
settings:
|
||||
repo: ${CI_FORGE_URL}/${CI_REPO}
|
||||
dockerfile: docker/backend.Dockerfile
|
||||
context: .
|
||||
tag:
|
||||
- latest
|
||||
- ${CI_COMMIT_SHA:0:8}
|
||||
target: production
|
||||
registry:
|
||||
from_secret: docker_registry
|
||||
username:
|
||||
from_secret: docker_username
|
||||
password:
|
||||
from_secret: docker_password
|
||||
|
||||
docker-frontend:
|
||||
image: woodpeckerci/plugin-docker-buildx
|
||||
depends_on:
|
||||
- test-frontend
|
||||
settings:
|
||||
repo: ${CI_FORGE_URL}/${CI_REPO}
|
||||
dockerfile: docker/frontend.Dockerfile
|
||||
context: .
|
||||
tag:
|
||||
- latest
|
||||
- ${CI_COMMIT_SHA:0:8}
|
||||
target: production
|
||||
registry:
|
||||
from_secret: docker_registry
|
||||
username:
|
||||
from_secret: docker_username
|
||||
password:
|
||||
from_secret: docker_password
|
||||
|
||||
deploy:
|
||||
image: appleboy/drone-ssh
|
||||
depends_on:
|
||||
- docker-backend
|
||||
- docker-frontend
|
||||
settings:
|
||||
host:
|
||||
from_secret: deploy_host
|
||||
username:
|
||||
from_secret: deploy_username
|
||||
key:
|
||||
from_secret: deploy_key
|
||||
port: 22
|
||||
script:
|
||||
- cd /opt/glibredecision
|
||||
- docker compose -f docker/docker-compose.yml pull
|
||||
- docker compose -f docker/docker-compose.yml up -d --remove-orphans
|
||||
- docker image prune -f
|
||||
Reference in New Issue
Block a user