/

Loading...
Deploy DataChonk on your own infrastructure for maximum control, security, and compliance.
| Component | Minimum | Recommended |
|---|---|---|
| CPU | 2 cores | 4+ cores |
| Memory | 4 GB | 8+ GB |
| Storage | 20 GB SSD | 50+ GB SSD |
| PostgreSQL | 14+ | 15+ |
| Redis | 6+ | 7+ |
The fastest way to get started. Clone the repository and run:
# Clone the self-hosted repository
git clone https://github.com/datachonk/self-hosted.git
cd self-hosted
# Copy and configure environment
cp .env.example .env
# Edit .env with your settings
# Start all services
docker compose up -d
# Check status
docker compose ps
# View logs
docker compose logs -f appversion: '3.8'
services:
app:
image: datachonk/datachonk:latest
ports:
- "3000:3000"
environment:
- DATABASE_URL=postgresql://postgres:password@db:5432/datachonk
- REDIS_URL=redis://redis:6379
- NEXTAUTH_SECRET=${NEXTAUTH_SECRET}
- NEXTAUTH_URL=${NEXTAUTH_URL}
- OPENAI_API_KEY=${OPENAI_API_KEY}
depends_on:
- db
- redis
db:
image: postgres:15
volumes:
- postgres_data:/var/lib/postgresql/data
environment:
- POSTGRES_DB=datachonk
- POSTGRES_PASSWORD=password
redis:
image: redis:7-alpine
volumes:
- redis_data:/data
volumes:
postgres_data:
redis_data:Configure DataChonk with these environment variables:
# Database connection
DATABASE_URL=postgresql://user:pass@host:5432/datachonk
# Authentication
NEXTAUTH_SECRET=your-secret-key-min-32-chars
NEXTAUTH_URL=https://datachonk.yourcompany.com
# AI Provider (at least one required)
OPENAI_API_KEY=sk-...
# Or use Azure OpenAI
AZURE_OPENAI_API_KEY=...
AZURE_OPENAI_ENDPOINT=https://your-resource.openai.azure.com# Redis for caching (recommended)
REDIS_URL=redis://localhost:6379
# GitHub OAuth (for GitHub integration)
GITHUB_CLIENT_ID=...
GITHUB_CLIENT_SECRET=...
# SMTP for email notifications
SMTP_HOST=smtp.example.com
SMTP_PORT=587
SMTP_USER=...
SMTP_PASSWORD=...
SMTP_FROM=noreply@yourcompany.com
# Observability
SENTRY_DSN=https://...
LOG_LEVEL=info
# License (for enterprise features)
DATACHONK_LICENSE_KEY=...For production deployments, use our Helm chart:
# Add the DataChonk Helm repository
helm repo add datachonk https://charts.datachonk.dev
helm repo update
# Install with custom values
helm install datachonk datachonk/datachonk \
--namespace datachonk \
--create-namespace \
-f values.yamlreplicaCount: 2
image:
repository: datachonk/datachonk
tag: latest
ingress:
enabled: true
className: nginx
hosts:
- host: datachonk.yourcompany.com
paths:
- path: /
pathType: Prefix
tls:
- secretName: datachonk-tls
hosts:
- datachonk.yourcompany.com
postgresql:
enabled: true # or use external
auth:
database: datachonk
redis:
enabled: true
architecture: standalone
resources:
requests:
cpu: 500m
memory: 1Gi
limits:
cpu: 2000m
memory: 4GiAlways use HTTPS in production. Configure TLS termination at your load balancer or ingress.
Use SSL/TLS for database connections. Set ?sslmode=require in DATABASE_URL.
Store sensitive values in Kubernetes Secrets, HashiCorp Vault, or AWS Secrets Manager - not in plain text.
DataChonk only needs outbound access to AI providers. Restrict inbound access to your corporate network or VPN.
DataChonk stores all data in PostgreSQL. Regular backups are essential:
#!/bin/bash
# Daily backup script
DATE=$(date +%Y%m%d)
BACKUP_DIR=/backups/datachonk
# PostgreSQL backup
pg_dump $DATABASE_URL | gzip > $BACKUP_DIR/db_$DATE.sql.gz
# Keep last 30 days
find $BACKUP_DIR -name "db_*.sql.gz" -mtime +30 -delete
# Upload to S3 (optional)
aws s3 cp $BACKUP_DIR/db_$DATE.sql.gz s3://your-bucket/backups/