DigitalOcean
Deploy Inboxorcist on DigitalOcean App Platform.
DigitalOcean App Platform provides managed infrastructure with easy scaling.
App Spec Deployment
Step 1: Fork the Repository
Fork the Inboxorcist repository to your GitHub account.
Step 2: Update App Spec
Edit deploy/do-app-spec.yaml and replace YOUR_USERNAME with your GitHub username:
github:
repo: YOUR_USERNAME/inboxorcist
branch: mainStep 3: Create the App
Using the DigitalOcean CLI:
doctl apps create --spec deploy/do-app-spec.yamlOr through the dashboard:
- Log in to DigitalOcean
- Go to Apps > Create App
- Select GitHub and connect your repository
- Choose Use App Spec and upload
deploy/do-app-spec.yaml
Step 4: Configure Environment Variables
In the App settings, add these environment variables:
# Required - Security
JWT_SECRET=your-jwt-secret-min-32-chars
ENCRYPTION_KEY=your-64-character-hex-encryption-key
# App URL (your DigitalOcean domain)
APP_URL=https://your-app.ondigitalocean.app
# Optional - Google OAuth (can also be configured via /setup UI)
# GOOGLE_CLIENT_ID=your-client-id.apps.googleusercontent.com
# GOOGLE_CLIENT_SECRET=GOCSPX-your-secretMark JWT_SECRET and ENCRYPTION_KEY as Secret.
Google OAuth credentials are optional. You can configure them via the web UI at /setup after deployment.
Step 5: Deploy
Click Deploy or push to the connected branch.
App Spec Reference
name: inboxorcist
region: nyc
services:
- name: inboxorcist
dockerfile_path: Dockerfile
github:
repo: YOUR_USERNAME/inboxorcist
branch: main
deploy_on_push: true
http_port: 6616
instance_size_slug: basic-xxs
instance_count: 1
health_check:
http_path: /health
initial_delay_seconds: 10
period_seconds: 30
envs:
- key: JWT_SECRET
scope: RUN_TIME
type: SECRET
- key: ENCRYPTION_KEY
scope: RUN_TIME
type: SECRET
- key: APP_URL
scope: RUN_TIME
value: https://your-app.ondigitalocean.appDatabase Options
Option A: DigitalOcean Managed PostgreSQL (Recommended)
Add a managed database to your app spec:
databases:
- name: db
engine: PG
version: "16"
size: db-s-dev-database
num_nodes: 1Then reference it in your service:
services:
- name: inboxorcist
envs:
- key: DATABASE_URL
scope: RUN_TIME
value: ${db.DATABASE_URL}Option B: External PostgreSQL
If you have an existing PostgreSQL database (e.g., Supabase, Neon, or your own):
- Go to your app's Settings > Environment Variables
- Add
DATABASE_URLwith your connection string:postgres://user:password@host:5432/dbname
Option C: SQLite (Default)
If no DATABASE_URL is set, Inboxorcist uses SQLite automatically.
SQLite data may not persist across DigitalOcean deployments. For production, use managed PostgreSQL.
Custom Domain
- Go to your app's Settings > Domains
- Click Add Domain
- Enter your domain name
- Configure DNS records as instructed
- Update environment variable:
APP_URL=https://yourdomain.comScaling
Vertical Scaling
Change instance_size_slug:
| Slug | vCPUs | RAM | Price |
|---|---|---|---|
basic-xxs | 1 | 512 MB | $5/mo |
basic-xs | 1 | 1 GB | $10/mo |
basic-s | 1 | 2 GB | $20/mo |
basic-m | 2 | 4 GB | $40/mo |
Horizontal Scaling
Increase instance_count:
instance_count: 3Horizontal scaling requires PostgreSQL instead of SQLite to share state between instances.
Monitoring
Logs
View in Runtime Logs tab or:
doctl apps logs <app-id>Metrics
Monitor in the Insights tab:
- CPU usage
- Memory usage
- Request count
- Response times
Alerts
Configure alerts in Settings > Alerts:
- CPU threshold
- Memory threshold
- Deployment failures
Updating
DigitalOcean automatically deploys on push to the connected branch.
Manual redeploy:
doctl apps create-deployment <app-id>Or click Deploy in the dashboard.
Pricing
App Platform pricing:
| Plan | Price | Features |
|---|---|---|
| Starter | $5/mo | 1 vCPU, 512MB RAM |
| Basic | $10/mo+ | Scalable, custom domains |
| Professional | $12/mo+ | Autoscaling, dedicated resources |
PostgreSQL Dev database: $7/mo additional.
Troubleshooting
Build Fails
Check build logs in Deployments tab. Common issues:
- Dockerfile path incorrect
- Missing build dependencies
App Crashes
Check runtime logs for:
- Missing environment variables
- Health check failures
- Memory limits exceeded
Database Connection Issues
Verify DATABASE_URL:
- Go to database settings
- Copy connection string
- Ensure it's set in app environment
Slow Performance
Consider upgrading instance size or enabling autoscaling.
