{
  "slug": "install/bare-metal",
  "title": "Install on bare metal",
  "description": "Run Cuitty as a single Bun binary on a Linux VM, with systemd-managed services for production durability.",
  "url": "https://cuitty.com/docs/install/bare-metal",
  "markdown_url": "https://cuitty.com/docs/install/bare-metal.md",
  "json_url": "https://cuitty.com/docs/install/bare-metal.json",
  "frontmatter": {
    "title": "Install on bare metal",
    "description": "Run Cuitty as a single Bun binary on a Linux VM, with systemd-managed services for production durability.",
    "order": 3,
    "section": "Install",
    "updatedAt": "2026-04-27"
  },
  "headings": [
    {
      "depth": 1,
      "slug": "install-on-bare-metal",
      "text": "Install on bare metal"
    },
    {
      "depth": 2,
      "slug": "prerequisites",
      "text": "Prerequisites"
    },
    {
      "depth": 2,
      "slug": "download",
      "text": "Download"
    },
    {
      "depth": 2,
      "slug": "configure",
      "text": "Configure"
    },
    {
      "depth": 2,
      "slug": "systemd-unit",
      "text": "systemd unit"
    },
    {
      "depth": 2,
      "slug": "reverse-proxy",
      "text": "Reverse proxy"
    }
  ],
  "body_markdown": "# Install on bare metal\n\nCuitty ships a single Bun-bundled binary suitable for running directly on a Linux VM without containers. This is the lowest-overhead deployment option.\n\n## Prerequisites\n\n- Linux x86_64 or arm64\n- Postgres 15+ (local or remote)\n- A SpiceDB binary on `PATH`\n- Bun 1.3+ (only required to rebuild from source)\n\n## Download\n\n```bash\ncurl -fsSL https://releases.cuitty.com/portal/latest/portal-linux-x86_64 \\\n  -o /usr/local/bin/cuitty-portal\nchmod +x /usr/local/bin/cuitty-portal\n```\n\n## Configure\n\nCreate `/etc/cuitty/portal.env`:\n\n```dotenv\nDATABASE_URL=postgres://cuitty@localhost/cuitty\nSPICEDB_URL=localhost:50051\nSPICEDB_TOKEN=...\nBETTER_AUTH_SECRET=...\nPORT=7700\nDATA_DIR=/var/lib/cuitty\n```\n\n## systemd unit\n\n`/etc/systemd/system/cuitty-portal.service`:\n\n```ini\n[Unit]\nDescription=Cuitty Portal\nAfter=network.target postgresql.service\n\n[Service]\nType=simple\nEnvironmentFile=/etc/cuitty/portal.env\nExecStart=/usr/local/bin/cuitty-portal\nRestart=on-failure\nUser=cuitty\nGroup=cuitty\nWorkingDirectory=/var/lib/cuitty\n\n[Install]\nWantedBy=multi-user.target\n```\n\n```bash\nsystemctl daemon-reload\nsystemctl enable --now cuitty-portal\n```\n\n## Reverse proxy\n\nRun Caddy or nginx in front of the portal for TLS termination. The portal expects to be reached over HTTPS in production for cookie-based auth to work correctly.",
  "links_out": []
}