Complete implementation ready for Coolify: - Node.js 22 + Fastify + socket.io backend - PostgreSQL 16 + Redis 7 services - Docker Compose configuration - Deployment scripts and documentation Co-Authored-By: Paperclip <noreply@paperclip.ing>
175 lines
5.8 KiB
Markdown
175 lines
5.8 KiB
Markdown
# J10 — Blocage Tests Live
|
||
|
||
**Date:** 2026-04-30
|
||
**Status:** Bloqué en attente environnement de test
|
||
|
||
## Livrables Code — ✅ 100% Terminés
|
||
|
||
Tous les artefacts J10 ont été créés et validés :
|
||
|
||
1. ✅ `scripts/bootstrap.sh` (syntaxe validée, 10 étapes vérifiées)
|
||
2. ✅ `docs/RUNBOOK-lan.md` (runbook complet 8 sections)
|
||
3. ✅ `docs/J10-VERIFICATION.md` (procédures de test)
|
||
4. ✅ Feature flag `FEATURE_MESSAGING_ENABLED` (implémenté + documenté)
|
||
5. ✅ `test/smoke-lan-2-agents.sh` (script automatisé pour setup 2 agents)
|
||
6. ✅ Commit `1b91e58` + nouveau script de test
|
||
|
||
## Reste à Exécuter — Tests Live
|
||
|
||
### Blocage Actuel
|
||
|
||
**Environnement de test indisponible** — ni Multipass ni Docker ne sont disponibles dans l'environnement Paperclip actuel pour exécuter :
|
||
|
||
1. Bootstrap Ubuntu from scratch
|
||
2. Test 2 agents WebSocket en conditions réelles
|
||
3. Capture screenshots/curl traces
|
||
|
||
### Options de Déblocage
|
||
|
||
**Option 1: Serveur Ubuntu LAN Barodine (cible Phase 1)**
|
||
|
||
Accès SSH au serveur Ubuntu LAN founder permettrait d'exécuter :
|
||
|
||
```bash
|
||
# Sur le serveur Ubuntu
|
||
sudo bash -c "$(curl -fsSL https://forgejo.barodine.net/barodine/agenthub/raw/branch/main/scripts/bootstrap.sh)"
|
||
|
||
# Depuis poste LAN
|
||
./test/smoke-lan-2-agents.sh <lan-ip>
|
||
# Puis test WebSocket manuel avec 2 clients
|
||
```
|
||
|
||
**Durée estimée:** < 1h avec serveur prêt
|
||
|
||
**Option 2: VM Multipass locale**
|
||
|
||
Si Multipass est installé sur machine du founder :
|
||
|
||
```bash
|
||
# Sur machine avec Multipass
|
||
multipass launch --name agenthub-test --disk 20G --memory 4G ubuntu-22.04
|
||
multipass exec agenthub-test -- sudo bash -c "$(curl -fsSL <bootstrap-url>)"
|
||
|
||
# Obtenir IP VM
|
||
VM_IP=$(multipass info agenthub-test | grep IPv4 | awk '{print $2}')
|
||
|
||
# Test depuis host
|
||
./test/smoke-lan-2-agents.sh $VM_IP
|
||
```
|
||
|
||
**Durée estimée:** < 30 min
|
||
|
||
**Option 3: Docker local (development)**
|
||
|
||
Si Docker Desktop/Engine disponible :
|
||
|
||
```bash
|
||
cd agenthub
|
||
docker compose -f compose.dev.yml up -d
|
||
|
||
# Test sur localhost
|
||
./test/smoke-lan-2-agents.sh localhost
|
||
```
|
||
|
||
**Durée estimée:** < 15 min
|
||
**Limite:** Teste compose.dev.yml, pas bootstrap.sh ni UFW
|
||
|
||
**Option 4: Délégation à humain**
|
||
|
||
Fournir les instructions et scripts aux founders pour qu'ils exécutent manuellement sur leur infrastructure.
|
||
|
||
**Durée estimée:** Dépend de disponibilité founders
|
||
|
||
## Artefacts Prêts pour Test
|
||
|
||
### 1. Bootstrap Script
|
||
|
||
**Fichier:** `scripts/bootstrap.sh`
|
||
**Usage:**
|
||
```bash
|
||
# Sur Ubuntu 22.04/24.04 LTS avec root/sudo
|
||
sudo bash scripts/bootstrap.sh
|
||
```
|
||
|
||
**Validation effectuée:**
|
||
- ✅ Syntaxe bash validée (`bash -n`)
|
||
- ✅ 10 étapes présentes et numérotées
|
||
- ✅ Permissions 755
|
||
- ✅ Idempotence design (conditions `if` pour skip existing)
|
||
|
||
### 2. Test Script 2 Agents
|
||
|
||
**Fichier:** `test/smoke-lan-2-agents.sh`
|
||
**Usage:**
|
||
```bash
|
||
# Prépare 2 agents + 1 room, affiche URLs WebSocket
|
||
./test/smoke-lan-2-agents.sh <lan-ip-or-localhost>
|
||
```
|
||
|
||
**Output:** Credentials JSON dans `/tmp/agenthub-smoke-test-creds.json`
|
||
|
||
**Flow de test:**
|
||
1. Health check
|
||
2. Créer Agent 1 + Agent 2
|
||
3. Générer API tokens
|
||
4. Échanger pour JWTs
|
||
5. Créer room de test
|
||
6. Afficher instructions WebSocket
|
||
7. Vérifier endpoint historique messages
|
||
|
||
**Test manuel WebSocket requis après:**
|
||
- Connecter 2 clients aux URLs affichées
|
||
- Join room
|
||
- Envoyer message Agent 1 → Agent 2
|
||
- Vérifier réception temps réel
|
||
- Vérifier persistance en DB
|
||
|
||
### 3. Runbooks
|
||
|
||
**Fichier:** `docs/RUNBOOK-lan.md`
|
||
**Sections prêtes:**
|
||
- Initial setup (bootstrap)
|
||
- UFW firewall (22/tcp + 3000/tcp LAN-only)
|
||
- Operations (start/stop/logs/update)
|
||
- Backup/restore
|
||
- Rollback (feature flag + version)
|
||
- Monitoring (healthz/readyz/metrics)
|
||
- Troubleshooting
|
||
|
||
**Fichier:** `docs/J10-VERIFICATION.md`
|
||
**Checklist de test complète:** 5 phases
|
||
|
||
## Done Criteria Mapping
|
||
|
||
| Critère (BARAAA-28) | Status | Blocage |
|
||
|--------------------------------------------------------------|--------------|------------------------------|
|
||
| `bootstrap.sh` rejoué de zéro Ubuntu → stack < 15 min | ⏸️ Prêt | Pas d'Ubuntu disponible |
|
||
| 2 agents Paperclip échangent message persisté LAN | ⏸️ Prêt | Pas de serveur qui tourne |
|
||
| Message retrouvé historique après reconnexion | ⏸️ Prêt | Pas de serveur qui tourne |
|
||
| `RUNBOOK-lan.md` couvre setup/deploy/restore/rollback | ✅ Done | - |
|
||
| UFW rules documentées | ✅ Done | - |
|
||
| Feature flag `messaging.enabled` | ✅ Done | - |
|
||
| Screenshot/curl trace LAN attaché issue | ⏸️ Prêt | Pas de serveur qui tourne |
|
||
| Démo founder live LAN Barodine | ⏸️ Prêt | Attente serveur founder |
|
||
|
||
**Statuts:**
|
||
- ✅ Done — Livrable code terminé et validé
|
||
- ⏸️ Prêt — Script/doc prêt, attente exécution sur infra
|
||
|
||
## Recommandation
|
||
|
||
**Créer child issue pour l'exécution des tests** avec assignation à un agent ayant accès à l'infrastructure Ubuntu/Docker, ou délégation aux founders humains.
|
||
|
||
**Alternative immédiate:** Si un founder a Docker Desktop, Option 3 permet de valider rapidement le flow complet (sauf bootstrap.sh et UFW).
|
||
|
||
## Contact Points
|
||
|
||
**Unblock owner:** Founders Barodine (accès serveur Ubuntu LAN ou Multipass/Docker local)
|
||
|
||
**Unblock action:** Fournir accès SSH au serveur Ubuntu LAN, ou confirmer disponibilité Multipass/Docker Desktop pour test local.
|
||
|
||
**Fallback minimal:** Exécuter `compose.dev.yml` localement + test script, attacher traces à BARAAA-28, noter divergence avec bootstrap LAN dans commentaires.
|
||
|
||
---
|
||
|
||
**Next:** Attente réponse founders sur disponibilité infrastructure de test.
|