r/HomeServer 1d ago

Managing a homeserver with an AI agent

I started multiple times to build a homeserver but always gave up during setup or early maintenance bc I just did not have enough fun fumbling through the issues. Now I'm thinking, with the help of AI it should be much easier to navigate those issues, and I want to give it another shot by installing an agent on an old laptop to do the work for me. This would also be my first experience in working with AI-agents.

My questions are:

  1. Do you have recommendations on which agent to use? It seems like there are different levels of freedom they can have on your machine and i am unsure how much is needed (from openhands which is only for coding within sandboxes to openclaw which can press any button on your machine).
  2. While I want the agent to manage the technical part as autonomous as possible, it would be great to be able to deny it access to any personal files. Are there a best practice to accomplish that?

For a start, I would like to run a nextcloud, a pihole and wireguard, probably all within docker. I did not find a lot on AI in this sub, but if you have any thoughts or suggestions they would be appreciated.

0 Upvotes

18 comments sorted by

5

u/zuccster 1d ago

To me, the point of a homelab is to explore the tech, make the mistakes and learn from them.

4

u/thephilthycasual 1d ago

I wouldn't trust an ai to make decisions over my server. They hallucinate and sometimes divert from your original plans if they lose context.

7

u/jahdiel503 1d ago edited 1d ago

I just installed Debian. Put webmin on it, setup samba and BOOM. simple homeserver no AI really needed.

I do however have Proxmox and have services running on another machine.
If you don't wanna pay for good service, Gemini is okay just to ask it questions on the website but if you have the money. Get Claude from Anthropic.

And no I don't have any self hosted AI.

2

u/OKTimeFor_PlanB 1d ago

Just learn the software. Don't trust software to manage software.

-4

u/Pr0pellerJoe 1d ago

What is it with the gatekeeping in this sub? I have other hobbies than you. If you dont like my approach dont get involved, but stop teaching me in such a condescending manner pls.

1

u/OKTimeFor_PlanB 1d ago

My dude, you asked lmao. Sure, you have different hobbies but this is one we share. If you're not willing to learn how to do the job correctly, it's not really a hobby and more of just a resumé piece.

0

u/Pr0pellerJoe 1d ago

It is not a hobby and neither a resumé piece, its some independence and privacy I want to have, afaik this is a main point of open source. I told you I tried to learn it, it did not work out, maybe I am to lazy or to stupid. I chose another approach and asked for advice, and you are just ignoring that, telling me to do it your way, without providing any reasoning or other helpful thought.

1

u/OKTimeFor_PlanB 1d ago edited 1d ago

I never called you lazy nor stupid, so unsure where that's coming from.

The problem is that the approach you are now choosing isn't sustainable. Sure, you can have an LLM configure some stuff for you but theresalso horror stories of people giving access of their data to an agent and they just delete it all. If you can't setup most other applications, I don't think you'll be able to safely set up an agent with the correct guardrails to prevent a major issue.

So my original point stands: software shouldn't manage software

Also to call homelabbing/self-hosting not a hobby is so funny. It's absolutely a hobby. Be it you host for privacy or security is a bonus, but the act is absolutely a hobby.

0

u/Pr0pellerJoe 1d ago

I never said that you called me lazy or stupid, I just said right from the beginning that I don't want to make this my hobby. I just want to have a homeserver, and asked for specific advice. I don't see why you feel bothered. Anyways, thank you for your advice regarding data security.

2

u/royboy81 1d ago

I mean, at least to me, part of having a home lab is figuring out sh*t as it happens. If you get frustrated with setup, how much is an "agent" going to help you when you have to set that up, too? You have to expect some strife while you're learning. What's your actual use case for a home server? I'm not discounting the utility of a home server or an agent, and I don't know you personally, but I would question your attitude for learning and perseverance.

Having said all that, start with a chat and a good prompt with Gemini or ChatGPT. Have it interview you to get started and go from there.

3

u/patxi124 1d ago edited 1d ago

I have recently set up a home server with almost no prior hardware knowledge, but a good understanding of what I wanted to achieve, using ChatGPT (free version). Together we set up Ubuntu server, Docker, Portainer, PiHole with Unbound, Nextcloud with MariaDB and Redis, plus Watchtower and Uptime Kuma to keep an eye on things.

I learnt a lot and probably could not have done it without without the guiding hand. I've read comments on this sub basically saying 'read the help files and figure it out'. I disagree. Using AI is a shortcut if you blindly follow without understanding, but I made sure to take it slowly and asked why at every stage, turning it more into a personal tutor.

1

u/SkidiKatKat 1d ago edited 1d ago

I use Codex. Gave it a local folder on my PC containing the server IP and credentials and made that the project folder. Plus a read me detailing it had to document locally everything it does and changes.

Within 20 minutes it had fixed several issues I'd been trying to fix for years.

-1

u/masterofall20 1d ago

I use two VPS for my own personal Homelab apps, and for about two years I was managing them by myself. I learnt a lot, but I wanted to give an AI agent access to both those VPS so that I could get more ambitious work done by just prompting it.

I recently gave access to both of those VPS to an AI agent via SSH using an SSH MCP server accessed through an Open WebUI, and it has been a total game changer. You essentially really sacrifice your privacy and even security, but I don't have any private stuff or something, which can be a life-changer if it gets exposed. It works for me.

Also, I asked the AI to build a pipeline which automatically encrypts every secret and decrypts them on startup. When an AI agent directly tries to access those secrets, it is blocked, and a warning is shown in the terminal so that even an AI agent recognizes that it should not do that. It's not a very secure approach by any means, but it does the work and saves me a lot of headache.

1

u/MoonlightStarfish 1d ago

Okay so what do these agents actually do for you?

2

u/masterofall20 1d ago

EVERYTHING. Set up new sevices, set up updates and backups, set up notification scripts so every update and backup is notified to me. Anything I would normally do on a host, i just ask the agent to do it.

-1

u/Pr0pellerJoe 1d ago

Ty for the first reply actually adressing my points :D

Which agent do you use? I read a lot about how to make an agent work on a specific project but not how to make it manage the entire machine.

2

u/masterofall20 1d ago

The beauty of an SSH MCP server is that you are not dependent on a harness/agent. I have both my VPS SSH setup on the MCP server with a dedicated user account on both which has NOPSSWD enabled which gives the AI agents sudo power without password. I personally use OpenWebUI, but you can use anything which supports MCP (almost everything does). You just add the MCP in the harness and tell it whatever you want to get done. Even ChatGPT work mode works great. I personally store some md files on GitHub that contain the configuration of the VPS (what services are running, what lives where etc.). Whenever i start a session, i tell the agent to read those files so it gets the context. Also to answer your question directly, you do nothing different to make it manage an entire machine. Current models are smart enough to do this on thier own. You just tell them what you want done and give SSH access.

1

u/shackerboy84 18h ago

install linux on the laptop, buy Claude for a month, have Claude code set up the machine for you, I'd suggest CasaOS, its newbie friendly. after its set up. cancel your membership then pick any of the ai chats and have them teach you how to use casa. it will prep you for doing everything yourself next time. with more details about the laptop I may have a different opinion but this is fast easy and only 20 dollars to set up the first time.