[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"project-116812":3},{"id":4,"name":5,"fullName":6,"owner":7,"repo":5,"description":8,"homepage":9,"htmlUrl":10,"language":11,"languages":10,"totalLinesOfCode":10,"stars":12,"forks":13,"watchers":14,"openIssues":15,"contributorsCount":15,"subscribersCount":15,"size":15,"stars1d":14,"stars7d":16,"stars30d":16,"stars90d":15,"forks30d":15,"starsTrendScore":17,"compositeScore":18,"rankGlobal":10,"rankLanguage":10,"license":19,"archived":20,"fork":20,"defaultBranch":21,"hasWiki":20,"hasPages":20,"topics":22,"createdAt":10,"pushedAt":23,"updatedAt":24,"readmeContent":25,"aiSummary":10,"trendingCount":15,"starSnapshotCount":15,"syncStatus":26,"lastSyncTime":27,"discoverSource":28},116812,"selfhostlayer","mddanishyusuf\u002Fselfhostlayer","mddanishyusuf","The self-hosted Vercel","https:\u002F\u002Fselfhostlayer.com\u002F",null,"TypeScript",127,11,1,0,12,14,52.44,"Other",false,"main",[],"2026-11-19 14:40:40","2026-11-23 17:34:19","\u003Cdiv align=\"center\">\n\n\u003Ch1>Self Host Layer\u003C\u002Fh1>\n\n\u003Cp>\u003Cstrong>The self-hosted Vercel, on a $5 server you own. No Docker.\u003C\u002Fstrong>\u003C\u002Fp>\n\n\u003Cp>Push to GitHub and your app is live with HTTPS.\u003Cbr\u002F>Domains, databases, backups and alerts from a web panel that runs on your own server.\u003C\u002Fp>\n\n\u003Cp>\n\u003Ca href=\"https:\u002F\u002Fselfhostlayer.com\">Website\u003C\u002Fa> ·\n\u003Ca href=\"https:\u002F\u002Fselfhostlayer.com\u002Fdocs\">Docs\u003C\u002Fa> ·\n\u003Ca href=\"#quick-start\">Quick start\u003C\u002Fa> ·\n\u003Ca href=\"CONTRIBUTING.md\">Contributing\u003C\u002Fa>\n\u003C\u002Fp>\n\n\u003Cp>\n\u003Cimg alt=\"License: MIT\" src=\"https:\u002F\u002Fimg.shields.io\u002Fbadge\u002Flicense-MIT-blue\">\n\u003Cimg alt=\"Runs on Ubuntu and Debian\" src=\"https:\u002F\u002Fimg.shields.io\u002Fbadge\u002Fruns%20on-Ubuntu%20%7C%20Debian-orange\">\n\u003Cimg alt=\"No Docker\" src=\"https:\u002F\u002Fimg.shields.io\u002Fbadge\u002Fdocker-not%20needed-lightgrey\">\n\u003Cimg alt=\"GitHub stars\" src=\"https:\u002F\u002Fimg.shields.io\u002Fgithub\u002Fstars\u002Fmddanishyusuf\u002Fselfhostlayer?style=social\">\n\u003C\u002Fp>\n\n\u003C\u002Fdiv>\n\n```sh\ncurl -fsSL https:\u002F\u002Fget.selfhostlayer.com | bash\n```\n\n\u003Cp align=\"center\">\n  \u003Cimg src=\".github\u002Fassets\u002Fhero-overview.png\" alt=\"A project's overview in the Self Host Layer panel: status, runtime, memory, sandbox score, the live site and CPU and memory charts\" width=\"100%\">\n\u003C\u002Fp>\n\n## Why\n\nVercel is lovely until the bill. Docker-based panels want a bigger server and hide your apps inside containers. Self Host Layer does what you'd do by hand (`git pull`, install, build, restart, a web server config, a certificate), done properly:\n\n- **More apps per dollar.** No Docker. The panel idles at about 130 MB, so a 1 GB server runs many small apps.\n- **Nothing hidden, no lock-in.** Every app is a plain folder, a Linux user, a systemd unit and a Caddy site you can read. Remove the panel and your apps keep running.\n- **Safe by default.** Each app runs sandboxed as its own user with its own memory limit, so one app can't read or slow down another.\n\n## Quick start\n\n**You need** a fresh server with Ubuntu 24.04, Ubuntu 26.04 or Debian 12 (x86_64 or arm64), 1 GB RAM or more, 10 GB free disk, and ports 80 and 443 open. Any VPS works: Hetzner, DigitalOcean, Vultr, Linode…\n\n**1. Install.** SSH in as root and run:\n\n```sh\ncurl -fsSL https:\u002F\u002Fget.selfhostlayer.com | bash\n```\n\nIt takes a few minutes and ends with your panel's address and a one-time setup token:\n\n```\n┌──────────────────────────────────────────────────────────────┐\n│  Self Host Layer is ready\n│\n│  Open:         https:\u002F\u002F203-0-113-7.sslip.io\n│  Setup token:  ••••••••••••••••\n│  (valid 24h, works once; re-run the installer for a new one)\n└──────────────────────────────────────────────────────────────┘\n```\n\n**2. Create your account.** Open the address, paste the token, pick an email and password, and turn on two-factor sign-in. The address already has a real Let's Encrypt certificate.\n\n**3. Connect GitHub.** Click **New project → Connect GitHub**. The panel creates a GitHub App that only you own, and you choose which repositories it can see.\n\n**4. Import a repo.** Pick a repository. The framework, package manager, build and start commands are detected for you; change anything you like, add environment variables, then **Deploy**. A minute later it's live at `https:\u002F\u002F\u003Capp>.\u003Cyour-ip>.sslip.io`.\n\n**5. Add your domain** (optional). In the project's **Domains**, add `example.com`. The panel shows the DNS record to create, checks that it points at your server, then switches over with HTTPS.\n\nFrom now on, every push to your branch deploys by itself. That's it.\n\n> Running the installer again is safe: it checks and repairs everything and keeps your settings. Every flag, what it changes on the server, and how to update or remove it: [docs\u002Finstall.md](docs\u002Finstall.md).\n\n## Features\n\n\u003Ctable>\n\u003Ctr>\n\u003Ctd width=\"50%\" valign=\"top\">\n\n**Push to deploy**\u003Cbr\u002F>\nEvery push builds and goes live with no downtime (blue\u002Fgreen), with one-click rollback. Next.js, Vite, Nuxt, Astro, Remix, Express and static sites, detected for you.\n\n\u003C\u002Ftd>\n\u003Ctd width=\"50%\" valign=\"top\">\n\n**Domains and HTTPS**\u003Cbr\u002F>\nYour own domains, checked through DNS before they go live, with certificates that renew themselves. Free `\u003Capp>.\u003Cip>.sslip.io` addresses out of the box.\n\n\u003C\u002Ftd>\n\u003C\u002Ftr>\n\u003C\u002Ftable>\n\n\u003Cimg src=\".github\u002Fassets\u002Ffeature-projects.png\" alt=\"The Projects page: each project's latest deployment, RAM and CPU, and status\" width=\"100%\">\n\n\u003Cimg src=\".github\u002Fassets\u002Ffeature-domains.png\" alt=\"The Domains page: every project's domains and their status\" width=\"100%\">\n\n\u003Ctable>\n\u003Ctr>\n\u003Ctd width=\"50%\" valign=\"top\">\n\n**Databases, no Docker**\u003Cbr\u002F>\nPostgres, MySQL (MariaDB), MongoDB, Redis and SQLite, a separate login per app, with a built-in data viewer.\n\n\u003C\u002Ftd>\n\u003Ctd width=\"50%\" valign=\"top\">\n\n**Backups**\u003Cbr\u002F>\nEncrypted, to any S3-compatible bucket (S3, R2, B2), with SQLite checked and every database dumped. Restore in one click.\n\n\u003C\u002Ftd>\n\u003C\u002Ftr>\n\u003C\u002Ftable>\n\n\u003Cimg src=\".github\u002Fassets\u002Ffeature-databases.png\" alt=\"The Databases page: Postgres, MySQL, Redis and SQLite with their status\" width=\"100%\">\n\n\u003Ctable>\n\u003Ctr>\n\u003Ctd width=\"50%\" valign=\"top\">\n\n**Logs and usage**\u003Cbr\u002F>\nLive build and app logs, every request, and CPU and memory charts for each app and the whole server.\n\n\u003C\u002Ftd>\n\u003Ctd width=\"50%\" valign=\"top\">\n\n**Alerts**\u003Cbr\u002F>\nTelegram, Discord, a webhook or email when a deploy fails, an app crash-loops, or a disk or certificate needs attention.\n\n\u003C\u002Ftd>\n\u003C\u002Ftr>\n\u003C\u002Ftable>\n\n\u003Cimg src=\".github\u002Fassets\u002Ffeature-requests.png\" alt=\"A project's request log: time, status, path, duration, size and client\" width=\"100%\">\n\n\u003Cimg src=\".github\u002Fassets\u002Ffeature-alerts.png\" alt=\"The Alerts page: an open disk alert and the channels to send alerts to\" width=\"100%\">\n\n**And also:** cron jobs as systemd timers · background workers and one-off commands · private files that aren't in Git · WordPress and Ghost sites in one click · one panel deploying to several servers · two-factor sign-in, an audit log, and locking the panel to your IP or Tailscale · one-click updates.\n\n## The `layer` command\n\nEverything is a plain systemd unit, so you can always SSH in. The `layer` command is a thin, readable wrapper:\n\n```sh\nlayer ps               # every app, its live color and domains\nlayer logs myapp -f    # follow an app's output (journalctl underneath)\nlayer score myapp      # the app's sandbox score from systemd\nlayer update           # update the panel, agent and CLI; apps keep running\nlayer repair           # put back anything edited by hand\nlayer access reset     # locked out of the panel? this lets you back in\n```\n\nAll commands: [docs\u002Fcli.md](docs\u002Fcli.md).\n\n## How it works\n\n```\n             your browser                 GitHub\n                  │                         │ webhooks, tarballs\n                  ▼                         ▼\n   ┌───────────────────────── your server ──────────────────────────┐\n   │  Caddy  ──►  panel (Next.js, user `layer`)                     │\n   │    │              │ unix socket, allowlisted actions only      │\n   │    │              ▼                                            │\n   │    │         agent (root): builds, units, Caddy, databases     │\n   │    ▼                                                           │\n   │  app-a@blue   app-b@green   …   each its own user, sandboxed   │\n   │  a systemd unit with a memory limit, data in \u002Fsrv\u002Fapps\u002F\u003Capp>   │\n   └────────────────────────────────────────────────────────────────┘\n```\n\n- **The panel** is a Next.js app that runs as an unprivileged user and listens only on a unix socket behind Caddy.\n- **The agent** is the only thing that runs as root. It accepts a fixed list of actions with strict validators (`packages\u002Fprotocol`) and writes plain systemd units and Caddy files.\n- **Each app** is built in a sandbox, then runs as its own Linux user under systemd with a memory limit. A deploy starts the new color, checks it's healthy, then switches traffic.\n\nThe full security model, including the honest limits: [docs\u002Fsecurity.md](docs\u002Fsecurity.md).\n\n## Docs\n\n| | |\n|---|---|\n| [Install](docs\u002Finstall.md) | Requirements, the one command, updating, repairing, removing |\n| [The panel, page by page](docs\u002Fpanel.md) | What every page does |\n| [Servers](docs\u002Fservers.md) | One panel, several servers |\n| [Sites](docs\u002Fsites.md) | WordPress and Ghost |\n| [The `layer` command](docs\u002Fcli.md) | Every CLI command and the raw command underneath |\n| [Security model](docs\u002Fsecurity.md) | Sandboxing, secrets, and the honest limits |\n| [Moving an app from pm2](docs\u002Fmoving-from-pm2.md) | Step by step, with your data |\n\nThe same docs, easier to read: [selfhostlayer.com\u002Fdocs](https:\u002F\u002Fselfhostlayer.com\u002Fdocs).\n\n## Develop\n\n\u003Cdetails>\n\u003Csummary>Run it locally, test it in a VM, and the repo layout\u003C\u002Fsummary>\n\n\u003Cbr\u002F>\n\nNeeds Node 24 (`.nvmrc`) and yarn 1. TypeScript runs directly through Node's type stripping, with no build step in development.\n\n```sh\nyarn install\nyarn test                 # vitest\nyarn typecheck            # tsc, no emit\nLAYER_FAKE_AGENT=1 yarn --cwd panel dev   # the panel on your machine, with a fake agent\nyarn build:installer      # → dist\u002Finstall.sh (one file)\nbash scripts\u002Fbuild-release.sh   # → dist\u002Flayer-\u003Cversion>.tar.gz\n```\n\n| Path | What |\n|---|---|\n| `installer\u002F` | `install.sh` plus `lib\u002F*.sh`, bundled into one file by `scripts\u002Fbuild-installer.sh` |\n| `agent\u002F` | The root helper: allowlisted actions over a unix socket, templates for units and Caddy files |\n| `packages\u002Fprotocol\u002F` | The action allowlist, validators and the agent client, shared by the agent, CLI and panel |\n| `packages\u002Fcli\u002F` | The `layer` command |\n| `panel\u002F` | The Next.js panel |\n| `system\u002F` | systemd units for the agent and the panel |\n| `docs\u002F` | User docs |\n\n**Test on a real Ubuntu in a local VM.** Install [Multipass](https:\u002F\u002Fcanonical.com\u002Fmultipass) (`brew install --cask multipass`), then:\n\n```sh\nscripts\u002Fdev-vm.sh up        # Ubuntu 24.04 VM, 2 CPU \u002F 2 GB RAM, like a small VPS\nscripts\u002Fdev-vm.sh release   # build a release and run the real installer with it\nscripts\u002Fdev-vm.sh verify    # check the server state the installer promises\nscripts\u002Fdev-vm.sh e2e       # agent and blue\u002Fgreen end-to-end tests\nscripts\u002Fdev-vm.sh ui        # browser tour of the panel: setup, 2FA, sign in\nscripts\u002Fdev-vm.sh lint      # shellcheck every script\nscripts\u002Fdev-vm.sh reset     # start again from a fresh box\n```\n\n`LAYER_VM_IMAGE=26.04` tests the other Ubuntu release. The VM has no public address, so real Let's Encrypt certificates still need a real server.\n\nTo try a local build on a server: run `bash scripts\u002Fbuild-installer.sh && bash scripts\u002Fbuild-release.sh 0.1.0`, copy `dist\u002Finstall.sh` and the tarball over, and run `bash install.sh --from-tarball layer-0.1.0.tar.gz` there.\n\n\u003C\u002Fdetails>\n\n## Contributing\n\nIssues and pull requests are welcome. Please read [CONTRIBUTING.md](CONTRIBUTING.md) first; for anything big, open an issue before writing code.\n\nFound a security problem? Please report it privately: [SECURITY.md](SECURITY.md).\n\nIf Self Host Layer is useful to you, a ⭐ helps other people find it.\n\n## License\n\n[MIT](LICENSE) © MVP Stack LLC. Use it, change it and ship it anywhere, commercially or not. The font files in `panel\u002Fapp\u002Ffonts\u002F` are licensed separately and aren't covered (see [LICENSE](LICENSE)).\n",2,"2026-11-24 04:54:16","CREATED_QUERY"]