Self-Hosting dotCMS on a VPS: A Complete Production Guide
Deploy Homarr Dashboard (Optional)
Homarr is a lightweight, self-hosted dashboard that gives you a single page to access all services running on your VPS.
This section assumes a domain of home.dotcms.info; please substitute in your actual domain for this.
1. Add DNS Record#
Add an A record: home.dotcms.info → YOUR_STATIC_IP
2. Deploy via Portainer#
- In Portainer, go to Stacks → Add Stack
- Name it
homarr - Paste the following Docker Compose:
services: homarr: container_name: homarr image: ghcr.io/homarr-labs/homarr:latest restart: unless-stopped volumes: - /var/run/docker.sock:/var/run/docker.sock - ./homarr/appdata:/appdata environment: - SECRET_ENCRYPTION_KEY=xxxxx ports: - '7575:7575' - Deploy the stack
3. Add to Caddy#
home.dotcms.info { reverse_proxy localhost:7575 }
Reload Caddy and open https://home.dotcms.info.
4. Configure Your Dashboard#
On first load, set a username, password, and theme (dark recommended). Create a board and add app shortcuts:
- dotCMS: URL
https://dotcms.info, upload the dotCMS logo - Portainer: URL
https://portainer.dotcms.info - Docker widget: Search for "docker" in the item browser — displays live container status directly on the dashboard using the Docker socket mounted in the compose file
Next up
Chapter 7: Deploy Dashdot for VPS Metrics (Optional)