Skip to main content

πŸš€ Deployment Guide

FirstBreath is deployed on a VPS managed by Dokploy, an open-source alternative to Vercel/Heroku.

Infrastructure Overview​

We run multiple isolated Docker Compose stacks that communicate via a shared network.

How to Deploy​

1. Push to Master​

We use GitOps. Every commit pushed to the main branch of a repository triggers a rebuild in Dokploy (via Webhook).

2. Manual Deployment (Dokploy UI)​

If auto-deploy fails or you need a manual rollback:

  1. Log in to https://dokploy.firstbreath.fr
  2. Go to the Project -> Service (e.g., hub-api).
  3. Click "Deploy".

Environment Variables​

Environment variables are managed in the Dokploy UI under the "Environment" tab of each service.

⚠️ Critical: Never commit .env files. Always check Dokploy vars if a service fails to start in production.

Troubleshooting​

"Bad Gateway" (502)​

Usually means the container is crashing or restarting.

  1. Check logs in Dokploy.
  2. Verify that the application is listening on the correct port (Backend: 3333, Frontend: 3000).

"Connection Refused" between services​

Ensure both services are attached to the monitor-net external network in their docker-compose.yml.