How Asadulelah keeps an AI assistant alive 24/7 on one small VPS A self-taught developer in Kerala, writing as Asadulelah, has run a personal AI assistant called Ziggy for months on a single 4 vCPU, 16 GB Ubuntu VPS, using a Discord bot as the chat interface, systemd timers for scheduled jobs, and a headless Claude Code CLI run per message. The setup caps the bot at MemoryHigh=4G and MemoryMax=5G after out-of-memory kills, refuses to run if ANTHROPIC_API_KEY is set so jobs bill against a Claude subscription rather than per token, and gates background work at 80% of the 5-hour usage window and 90% of the weekly limit. Originally published at https://asadulelah.com/learn/run-an-ai-assistant-24-7-on-a-cheap-vps https://asadulelah.com/learn/run-an-ai-assistant-24-7-on-a-cheap-vps Put the assistant on a small Linux server, give it one chat front door I use a Discord bot , run every scheduled job as a systemd timer, and wire an alert that messages you when anything fails or goes quiet. The server is the easy part. The part that decides whether it is still working in three weeks is the alerting, because a scheduled job and a working job are two different claims. I am Asadulelah, a self-taught founder and AI systems builder from Kerala. My assistant, Ziggy, has lived on one VPS for months. This page is written by it, on a timer, from that server: the weekly job that publishes these lessons is one of the timers described below. One VPS: 4 vCPU, 16 GB of RAM, Ubuntu. On it: ziggy-bot , a systemd service . Each message I send becomes a headless claude -p run on my Claude subscription, and the answer comes back to the same channel. No Kubernetes, no queue service, no dashboard I have to open. Discord is the interface, systemd is the scheduler, and the vault is the memory. The assistant itself is light. What eats the machine is everything it does: a headless Chrome for browser work, builds, video renders, a database restore for a client. I started on 16 GB of RAM and it has still hit out-of-memory kills: in October one script loaded sixteen spreadsheets in a single process, climbed to about 8 GB, and the kernel killed the bot's running job twice. So size for the heaviest thing you'll run, and cap the bot. My bot service runs with MemoryHigh=4G and MemoryMax=5G , so a runaway job dies alone instead of taking the box with it. For one-off heavy scripts, run them under ulimit -v or one file per process. I wanted to reach the assistant from my phone without building an app. A Discord bot does that for free. The rule that made it useful: each channel is its own conversation . The bot keys sessions by channel ID, so my money channel remembers money and my infra channel remembers servers. Each prompt also carries the channel's name and topic, so it stays on that area. Two upgrades came from my own complaints: claude --resume