Date début : 09-12-2024 01:15 Date fin : 09-12-2024 01:30 Statut : ✅ Terminé
Documentation complète du système de déploiement HelloCar, incluant :
| Service | Image | Port | Container | Status |
|---|---|---|---|---|
| API | hellocar-api:prod | 4510 | hellocar-api-prod | 🟢 |
| Public | hellocar-public:prod | 4501 | hellocar-public-prod | 🟢 |
| Admin | hellocar-admin:prod | 4500 | hellocar-admin-prod | 🟢 |
┌─────────────────────────────────────────────────────────────────┐
│ Serveur PROD (192.168.1.11) │
├─────────────────────────────────────────────────────────────────┤
│ │
│ ┌─────────────────┐ ┌─────────────────┐ ┌─────────────────┐ │
│ │ hellocar-api │ │ hellocar-public │ │ hellocar-admin │ │
│ │ :4510 │ │ :4501 │ │ :4500 │ │
│ │ Elysia + Bun │ │ Qwik + Node │ │ Qwik + Node │ │
│ └────────┬────────┘ └────────┬────────┘ └────────┬────────┘ │
│ │ │ │ │
│ └────────────────────┼────────────────────┘ │
│ │ │
│ ┌───────────▼───────────┐ │
│ │ Docker Engine │ │
│ │ data-root: NFS │ │
│ └───────────────────────┘ │
│ │
└─────────────────────────────────────────────────────────────────┘
│
┌────────────▼────────────┐
│ NFS (192.168.1.10) │
│ /mnt/stock_36to/data/ │
│ - docker/prod/ │
│ - docker/secrets/ │
└─────────────────────────┘
conf.prod.gouroubleu.yml - Config déploiement PROD (branche main)conf.dev.gouroubleu.yml - Config déploiement DEV (branche develop)DEPLOYMENT.md - Documentation déploiement/mnt/stock_36to/data/docker/secrets/prod.env - Secrets PROD/mnt/stock_36to/data/docker/secrets/dev.env - Secrets DEV/tmp/hellocar/Dockerfile.api - Dockerfile API/tmp/hellocar/Dockerfile.public - Dockerfile Public/tmp/hellocar/Dockerfile.admin - Dockerfile Admin# Clone
git clone --branch main https://TOKEN@github.com/gouroubleu/hellocar.git /tmp/hellocar
# Build
cd /tmp/hellocar
docker build -f Dockerfile.{service} -t hellocar-{service}:prod .
# Run
docker run -d \
--name hellocar-{service}-prod \
--restart unless-stopped \
-p {PORT}:{PORT} \
-e NODE_ENV=production \
-e ... \
hellocar-{service}:prod
docker stop hellocar-{service}-prod
docker rm hellocar-{service}-prod
# Puis rebuild et run