Purgatory (p7y)
Self-hosted Docker sandboxes for agents: create one, deploy a compose stack, read its files and URLs
التثبيت
أضف هذا إلى إعدادات MCP في عميلك (Claude Desktop: claude_desktop_config.json، وCursor: .cursor/mcp.json، ويستخدم VS Code وغيره الصيغة نفسها «mcpServers»).
claude mcp add --transport http purgatory-p7y 'https://{purgatory_host}/mcp' --header 'Authorization: <Bearer <token>: a Purgatory access token (Access tokens page); a token limited to one sandbox gets only that sandbox'\''s tools>'
{
"mcpServers": {
"purgatory-p7y": {
"type": "http",
"url": "https://{purgatory_host}/mcp",
"headers": {
"Authorization": "<Bearer <token>: a Purgatory access token (Access tokens page); a token limited to one sandbox gets only that sandbox's tools>"
}
}
}
}
التوثيق
مأخوذ من ملف README للمشروع على GitHub ويُحدَّث أسبوعيًا. تفتح الروابط على GitHub.
Purgatory (p7y)
[!NOTE] Early, before 1.0. It works and is tested (CI on every change, releases with a changelog), but expect rough edges, and breaking changes between minor versions.
Self-hosted sandboxes for your team and their AI agents: everyone gets their own Docker, every app gets a URL, idle sandboxes sleep.
Think of it as a self-hosted Vercel for the apps your team and its agents spin up. Today you deploy with docker compose; git-based builds are on the roadmap.
About 10 seconds from New sandbox to your own Docker and a public URL for your app; a sleeping sandbox is back in under 10. (Measured with the images already pulled: the first sandbox on a new server also downloads them.)
- Its own Docker daemon for every sandbox (with a Portainer UI if you want one)
- A public URL for every app, and TLS addresses for Postgres, Redis and SSH
- Sleeps when idle, wakes on the next request; a delete archives, nothing is lost
- Made for agents: tokens limited to one sandbox, an agent guide, an MCP server and a Claude Code plugin (
/plugin marketplace add p7y-dev/p7y, then/p7y:initconnects each project: Purgatory shows the line under Let your agent deploy…)
Hide the complexity. Keep it simple. Focus on what matters.
Purgatory abstracts away infrastructure complexity and operational overhead, providing an intuitive user experience that lets users focus on their work and business goals rather than managing the underlying technology.
Why Purgatory, and how it compares with a laptop, a cloud PaaS, a shared Docker host, Coolify and a VM for everyone · How it works: the components (Docker-in-Docker, frp, Traefik, Sablier), a sandbox's lifecycle and the path of a request
The same from a script or an agent
All real runs, in real time; press one to watch it.
With curl through the API, by an agent over the MCP server, and the MCP server by hand (JSON-RPC over HTTP, so even curl can call its tools).
Try it on your laptop
With Docker Desktop, or Docker Engine and the compose plugin on Linux, and ports 80 and 443 free (on Windows, in Git Bash or WSL):
mkdir p7y && cd p7y
curl -fsSLO https://github.com/p7y-dev/p7y/releases/latest/download/docker-compose.yml
curl -fsSL https://github.com/p7y-dev/p7y/releases/latest/download/setup.sh | bash # prints the admin password
docker compose up -d
Open http://p7y.lvh.me** (lvh.me and all its subdomains point to 127.0.0.1, so no DNS to set up), sign in as administrator with the password setup.sh printed, and press **New sandbox. The first one takes a minute or two while the images are pulled; after that about 10 seconds. Its app opens at its own http://<name>-….lvh.me address.
An app takes seconds to open the first time? In Chrome, Settings → Privacy and security → Security → Use secure DNS: with "your current service provider" each new
*.lvh.mename can wait for a slow or filtering resolver. Turn it off, or pick a provider such as Cloudflare (1.1.1.1).
To remove it: delete the sandboxes in the UI first (each is a compose project of its own, so the next step would leave them running), then docker compose down -v in the p7y directory, and delete the directory.
Install
On a Linux host with Docker Engine and the compose plugin, no clone needed (check the host first):
mkdir p7y && cd p7y
curl -fsSLO https://github.com/p7y-dev/p7y/releases/latest/download/docker-compose.yml
curl -fsSL https://github.com/p7y-dev/p7y/releases/latest/download/setup.sh | bash -s -- dev.example.com # .env with your domain and random secrets
docker compose up -d
Then sign in at http://p7y.<HOST_DOMAIN> (by default http://p7y.lvh.me).
When to use something else
Purgatory is for a team's apps and agents' deployments that should be up at a URL, cheaply, on your own server. For other jobs other tools fit better:
- Production that must scale and stay up → a cloud PaaS, or Coolify / Dokploy on your own servers
- Untrusted code from strangers → a microVM sandbox such as E2B or Docker Sandboxes (until Purgatory has a Kata runtime)
- Writing code in a cloud IDE → Coder or GitHub Codespaces
- An agent running short scripts from an SDK → E2B or Daytona
More in how it compares.
Documentation
p7y-dev.github.io/p7y: tutorials, install, configuration, let your agent deploy, MCP, API, and llms-full.txt for agents.
Security: where sysbox is installed, sandboxes run without a privileged container; without it they fall back to the privileged
dind, which suits a team that trusts each other, not hostile code. On a shared server install sysbox and setALLOWED_RUNTIMES=sysbox(details).
Contributing · Security issues · AGPL-3.0
Free to use, also commercially, on your own servers or for your customers. Changed it and people use it over the network? Then they get your changed source too, under the same license (AGPL-3.0). Every product built on Purgatory says so: Based on Purgatory (p7y), in its About page and its docs, is marked as changed, and does not take the names "Purgatory" or "p7y" (NOTICE). Versions up to 0.10.3 were released under Apache-2.0.
الأسئلة الشائعة
ما هو Purgatory (p7y)؟
Self-hosted Docker sandboxes for agents: create one, deploy a compose stack, read its files and URLs
كيف أثبّت Purgatory (p7y)؟
يعمل كخادم بعيد. في Claude Code: claude mcp add --transport http purgatory-p7y 'https://{purgatory_host}/mcp' --header 'Authorization: <Bearer <token>: a Purgatory access token (Access tokens page); a token limited to one sandbox gets only that sandbox'\''s tools>'. وفي العملاء الآخرين، الصق إعداد JSON من هذه الصفحة في إعدادات MCP الخاصة بهم.
هل يحتاج Purgatory (p7y) إلى مفتاح API؟
نعم. يتطلب Authorization، وتضبطها في إعداداته.
هل Purgatory (p7y) مفتوح المصدر؟
نعم. شيفرته متاحة على GitHub بترخيص AGPL-3.0.
من يصون Purgatory (p7y)؟
ينشره csakaszamok. يدرجه AI.tn لكنه لا يصونه ولا يوصي به.
من سجل MCP الرسمي. الإدراج ليس توصية: راجع شيفرة الخادم وصلاحياته قبل منحه الوصول إلى بياناتك.