Self-Hosting AgentSecrets: Own Your Secrets with Total Privacy
Description and use
Self‑hosting AgentSecrets gives full privacy and control over encrypted secrets using Docker, PostgreSQL, and the official CLI.
Problem
Teams want full control over encrypted credentials without sending data to third‑party servers.
Outcome
A fully private AgentSecrets deployment running in under 5 minutes, with encrypted secrets stored locally and accessible via the official CLI.
Workflow
- Clone agentsecrets-server repo
- Generate cryptographic keys and create .env
- Run docker-compose up -d
- Verify server health with curl
- Add HTTPS with Caddy (optional)
- Install official agentsecrets CLI on workstation
- Set CLI to point to self‑hosted server
- Initialize identity and bind to OS keychain
- Create project and set secrets via CLI
- Verify secrets stored and encrypted
- Optional: pin server per project
- Backup PostgreSQL database
Evidence
You can self-host the AgentSecrets server backend on your own VPS, home lab, or local server
Run docker-compose up -d
agentsecrets server set https://secrets.yourdomain.com
- Record date: 2026-09-06T11:52:03.140Z