Loading...
Loading...
Self-host Customermates on your own infrastructure with Docker Compose, PostgreSQL, and a production-ready Next.js app container.
This page shows how to run a self-hosted Customermates deployment with Docker Compose and PostgreSQL. If you are still deciding between deployment models, compare Self-Hosted vs Cloud first.
Self-hosted deployments run the community edition by default. Paid Enterprise features (Audit Logging, Single Sign-On, AI Agent, Whitelabeling) are not active in self-hosted deployments.
Before deploying, make sure you have:
For production usage, use a reverse proxy with HTTPS termination in front of the app container.
From the project root on your server:
cp .env.selfhost.template .env
chmod +x scripts/selfhost-setup.sh
./scripts/selfhost-setup.shThe setup script:
prisma migrate deploy.If you need to adjust configuration values, update .env and run the setup script again.
After setup, verify the containers are running:
docker compose psThen follow the application logs until the app reports it is ready:
docker compose logs -f appFor database diagnostics:
docker compose logs -f postgresOnce the app is reachable in the browser:
After this first login, continue with Managing Your Installation to handle updates, restarts, and troubleshooting workflows. For the operational trade-offs between deployment models, also see Self-Hosted vs Cloud.