A Self-Hosted Setup for Running AI Coding Agents 24/7 at Home

A developer describes a fully self-hosted environment where AI coding agents run in isolated virtual machines on a home server, reviewed through familiar tools.

A Self-Hosted Setup for Running AI Coding Agents 24/7 at Home
Source: Dmitry Kudryavtsev

The author wanted an always-on machine at home that could run AI coding agents around the clock, reachable over VPN from a laptop. The goal was to move work off the laptop, keep every component self-hosted, and make virtual machines easy to rebuild if one is corrupted or misbehaves. The hardware is a refurbished Dell Optiplex Micro running Proxmox, chosen for its small size, quiet operation and low power draw.

Networking is split into two VLANs. Supporting services such as git and CI/CD live in one, while development machines run in another, with only narrow openings between them. The idea is that a compromised agent cannot scan the wider network or reach management ports. Internal DNS and DHCP are handled by Technitium, which gives each dev machine a hostname under the author's domain. Code hosting and CI run on Forgejo, and deployments were moved to Semaphore UI so that agents never have access to production keys.

API keys stay out of the development VMs entirely. They are held by a proxy called agent-vault, which runs in its own container. Provisioning is handled by cloud-init and Ansible, driven by a small command-line tool the author wrote. Rather than building a custom web interface, the author relies on tmux and Forgejo issues, with a custom harness that reacts to webhooks and starts agent sessions.

Source: Dmitry Kudryavtsev


Posted

in

by

Tags: