Docs

Self-Hosted Deployment Guide

Deploy HRPulsar on your own infrastructure using Docker Compose.

Prerequisites

  • Docker 24.0+
  • Docker Compose 2.20+
  • 2+ vCPU, 4+ GB RAM, 20+ GB SSD (minimum)
  • A domain name (optional, for HTTPS)

Installation

1. Clone the repository

git clone https://github.com/hrpulsar/hrpulsar.git
cd hrpulsar

2. Configure environment

cp .env.example .env

Edit .env and set at minimum:

JWT_SECRET=your-random-secret-string-here
POSTGRES_PASSWORD=a-strong-database-password

3. Start all services

docker compose -f docker-compose.self-hosted.yml up -d

This starts 5 containers:

  • Caddy — Reverse proxy (ports 80/443)
  • Backend — FastAPI application (port 8000 internal)
  • Frontend — Next.js application (port 3000 internal)
  • PostgreSQL — Database with pgvector extension
  • Redis — Cache

4. Access the application

Create your first account at the registration page.

HTTPS with a Domain

To enable automatic HTTPS:

  1. Point your domain's A record to your server IP
  2. Edit deploy/Caddyfile: replace :80 with your domain (e.g., app.yourcompany.com)
  3. Restart Caddy: docker compose -f docker-compose.self-hosted.yml restart caddy

Caddy will automatically obtain a Let's Encrypt certificate.

Environment Variables

VariableRequiredDefaultDescription
JWT_SECRETYeschange-me-to-a-random-stringSecret key for JWT tokens
POSTGRES_PASSWORDYeshrpulsarPostgreSQL password
DATABASE_URLNoAuto-configuredPostgreSQL connection string
REDIS_URLNoAuto-configuredRedis connection string
ANTHROPIC_API_KEYNoClaude API key (for AI features)
OPENAI_API_KEYNoOpenAI API key (for AI features)
GEMINI_API_KEYNoGemini API key (for AI features)
LLM_PROVIDERNoclaudeLLM provider (claude, openai, gemini)
SMTP_HOSTNoSMTP server for email notifications
SMTP_PORTNo587SMTP port
SMTP_USERNoSMTP username
SMTP_PASSWORDNoSMTP password
S3_ENDPOINTNoS3/MinIO endpoint for file storage
S3_ACCESS_KEYNoS3 access key
S3_SECRET_KEYNoS3 secret key
S3_BUCKETNohrpulsarS3 bucket name

Upgrading

cd hrpulsar
git pull
docker compose -f docker-compose.self-hosted.yml build
docker compose -f docker-compose.self-hosted.yml up -d

Migrations run automatically on backend startup.

Backup & Restore

Backup

./scripts/backup_db.sh ./backups

Or set up a daily cron job:

crontab -e
# Add: 0 3 * * * /path/to/hrpulsar/scripts/backup_db.sh /path/to/backups

Restore

gunzip -c backups/hrpulsar_YYYYMMDD_HHMMSS.sql.gz | \
  docker compose exec -T postgres psql -U hrpulsar hrpulsar

Troubleshooting

Check service status

docker compose -f docker-compose.self-hosted.yml ps

View logs

docker compose -f docker-compose.self-hosted.yml logs backend
docker compose -f docker-compose.self-hosted.yml logs frontend

Health check

curl http://localhost:8000/health

Hardware Recommendations

UsersCPURAMDisk
Up to 1002 vCPU4 GB20 GB SSD
100-5004 vCPU8 GB50 GB SSD
500+8 vCPU16 GB100 GB SSD