Deployment Options
Loom can be deployed in several configurations:- Standalone Binary — Self-contained executable for single-user deployments
- OTP Release — Traditional Elixir release for server environments
- Docker Container — Containerized deployment (coming soon)
- Fly.io / Render — Platform-as-a-Service deployment
Standalone Binary Deployment
The simplest deployment for single-user or team use.Build
Deploy
Configuration
Set environment variables before running:OTP Release Deployment
For traditional server deployments with process supervision.Build
Deploy via Tarball
Systemd Service
Create/etc/systemd/system/loom.service:
Environment File
Create/etc/loom/environment:
Reverse Proxy Setup
Nginx
Caddy
Create aCaddyfile:
Cloud Platform Deployment
Fly.io
Loom works well on Fly.io with minimal configuration.Prerequisites
Initialize App
- App name:
loom - Region: closest to your users
- Database: No (Loom uses SQLite)
Set Secrets
Deploy
Custom Domain
Render
Deploy as a Web Service:- Connect GitHub repository
- Select Web Service
- Build Command:
mix deps.get && mix assets.deploy && mix release loom - Start Command:
_build/prod/rel/loom/bin/loom start - Add environment variables:
ANTHROPIC_API_KEYSECRET_KEY_BASEDATABASE_PATH=/var/data/loom.db
- Add persistent disk at
/var/data
Database Management
Backup
Restore
Automated Backups
Create/etc/cron.daily/loom-backup:
Monitoring
Phoenix LiveDashboard
Access athttps://loom.example.com/dashboard
- Metrics: Request rates, database queries, memory usage
- Processes: Active sessions, GenServer states
- ETS tables: Config, repo index, telemetry
- System info: Erlang VM stats, port usage
Telemetry
Loom emits Telemetry events for:[:loom, :session, :llm_request, :start | :stop | :exception][:loom, :session, :tool_execute, :start | :stop | :exception][:loom, :session, :cost, :update]
Health Check Endpoint
Loom doesn’t include a built-in health endpoint. Add one in your deployment:Security Considerations
Authentication
Loom doesn’t include built-in authentication. Add your own:API Keys
Store API keys securely:Firewall Rules
Database Permissions
Performance Tuning
BEAM VM
Set inconfig/runtime.exs:
SQLite Optimization
Scaling Considerations
Loom’s current architecture is optimized for single-node deployment:- Sessions are in-memory GenServers (lost on restart)
- Persistence uses SQLite (single-writer)
- PubSub broadcasts locally via Phoenix.PubSub
- Switch
Loom.Repoto PostgreSQL - Configure distributed PubSub with Redis
- Use
Hordefor distributed session registry
Troubleshooting
Logs
Remote Console
Memory Issues
Next Steps
- Release Configuration — Customize release settings
- Architecture Deep Dive — Understand how Loom works
- Contributing — Help improve Loom