▲ | godelski 3 days ago | |||||||
I've been on this mission but unfortunately also trying to defend my PhD in a month. But I do have a lot more Linux experience. Here's stuff that I think will really help. yt-dlp: a video downloaded. Originally designed for YouTube but supports a lot of sites. I suggest heavily aliasing this with options like sleep intervals, aria2, and make sure you download the user agent switcher. For YouTube you probably need to import cookies from a browser. But you'll be able to watch the videos without the ads. Btrfs: it's a file system, like ext4 or ntfs. Has a lot of useful things like being able to create subvolumes, raid, cache drives (or volumes), quotas, snapshots, etc. Think anything that you'd do with zfs but it's been easier to use and it has a copy on write system that helps dedupe. You can also compress the file system! I use duperemover. If it finds dupes it replaces one file with a link (which btrfs natively supports). It'll hash the files so run it early and then set up a job (use a systemd timer) Tailscale: take your network anywhere. God, tailscale is so fucking useful. You can even put it on a raspberry pi or your phones. It's nice to have it on an old phone which you can throw termux on and have a little server. I've used these to jump to another machine that has had issues where it could connect locally but not outside. You can also set up exit nodes so you can do things like push all your traffic through a vpn, make all your traffic use pihole, or just make it appear like you're somewhere else. You could use this to even make it effectively impossible for streaming services to know you're sharing an account. The data is going through whoever's house pays. If you get fancy you can set up rules to port specific traffic through specific locations but this is still a bit above my head. I just know it's possible. Unfortunately with iPhones you have less control. They can even break out of all this and you don't have full control. I need to get someone to explain more networking to me. Systemd: it's annoying at first but damn there's so much to it that is helpful. Use systemctl edit to edit your service files. The ones that come with services like jellyfin aren't nearly as locked down as they should be (I intend to push to them in a few months). You should also use systemd mount for your drives. You need a companion automount file but your drives will go offline when not being used. This will really help with reducing energy costs. Be sure to note that there's even configs for you gpus. It also lets you control a systems resources. There's also nspawn and vmspawn. I wish these were a bit more popular because they can do everything docker can and more. Nspawn is a suped up chroot so you can really containerize things and even run different Linux flavors (I've even been play around with running an arm container on my x86 machine). Using machinectl you can enable these as services and even create triggers to spin up or down. There's also importctl so if you create an image (or someone else does) you can just pull that! Which kinda makes it easier than docker in many cases other than the fact that not many people have made images (or publicly available). Docker's big win is popularity but systemd has felt nicer in every other way (documentation sucks). There's so much more to systemd and that's why it's loved and hated. There's a reason it stuck, it just is too damn useful (don't forget to check out homectl too) Ffmpeg: you probably know this one but it's also worth spending some time to learn it more and write some scripts. If you care more about storage I encode most stuff to av1 with nvenc. It's not archival but honestly I'm often getting 50% storage reductions and I can't tell the difference. Your source file probably wasn't archival grade anyways. Good enough for me. Hevc is also giving me good success. There's a bunch of other little tools that help. For example, I have my main computer sitting behind my TV. If I'm working on it I'm in it via ssh. Otherwise games and movies are on the TV. I use ydotool as a keyboard and just made a shortcut on my iPhone and a trivial script on my Android so I can push commands that way and use a wireless mouse. There's kconnect but it's been more a hassle than help ime. I did the same for backing up photos on from my phones (they wake the drives first). Android can rsync but for iPhone I can't find a good free solution other than writing the hackiest shortcut you've seen (ssh in, check if file exists, if not then write. You can't rsync, the fucking thing will timeout and despite there being terminal emulators for iPhone you can't access your photos from them. I've found zero ways to link them and I'm upset). Check out things like fail2ban to jail users that do too many logins. You can also use nspawn to containerize these services, spin up and down, and between btrfs, homectl, and pam it is really easy to containerize users. You can mount their volumes on demand and get their accounts syncing across your intranet. It's kinda crazy what you can do. My goal is to get some images so many of these things can start becoming plug and play. I'm getting close but obviously bigger priorities right now. I'd love help if anyone is interested. I'm not an expert in these domains so I'm sure I'm doing some things wrong but I'm learning a ton | ||||||||
▲ | steine65 2 days ago | parent [-] | |||||||
This is great. If you ever wrote about your entire setup I'd love to read it. Got a few new ideas from your post. To anyone reading, the most helpful tool for setting up my homelab is the community helper-scripts (formerly tteck, RIP). Those have saved me soooo much time, and showed me best practices in setup, and the list of scripts give you a good idea of tools that are commonly used. | ||||||||
|