Ansible/Puppet or NixOS would be better, but this is what works in Self Hosting.
Server Setup Basics for Self Hosting
61–70 of 75 posts
Re: Server Setup Basics for Self Hosting
#62I recommend checking out Caddy https://caddyserver.com/ >, which replaces both Nginx and Certbot in this setup. Tailscale https://tailscale.com/ > can remove the need to open port 22 to the world, but I wouldn't rely on it unless your VPS provider has a way to access the server console in case of configuration mistakes.
Re: Server Setup Basics for Self Hosting
#63Especially when writing a tutorial for beginners - please use the long-form flags (e.g. sudo usermod --append --groups sudo newuser) instead of short-form flags (e.g. sudo usermod -aG sudo newuser). Short-form flags make commands look like arcane voodoo magic. They make sense only to help you save time entering commands if you know them by heart already. Tutorials are read by beginners who are not necessarily familia…
"Acronyms seriously suck" ~Elon
[0] He wouldn't as he was a fan of recursive ones.
Re: Server Setup Basics for Self Hosting
#64Especially when writing a tutorial for beginners - please use the long-form flags (e.g. sudo usermod --append --groups sudo newuser) instead of short-form flags (e.g. sudo usermod -aG sudo newuser). Short-form flags make commands look like arcane voodoo magic. They make sense only to help you save time entering commands if you know them by heart already. Tutorials are read by beginners who are not necessarily familia…
Re: Server Setup Basics for Self Hosting
#65> Differential backups back up all the changes since the last full backup (...) An incremental backup backs up data that was changed since the last backup I'm not sure I understand the distinction?
They both do delta backups, but incremental bases it's delta on previous backup, while differential between the last full backup. To restore from an incremental you need the last full backup and all the incrementals inbetween. If you do say a full backup every month, you'd need up to 30 good incremental backup sets to be able to restore. For the differential you just need the last full backup in addition. Obviously t…
Re: Server Setup Basics for Self Hosting
#66Especially when writing a tutorial for beginners - please use the long-form flags (e.g. sudo usermod --append --groups sudo newuser) instead of short-form flags (e.g. sudo usermod -aG sudo newuser). Short-form flags make commands look like arcane voodoo magic. They make sense only to help you save time entering commands if you know them by heart already. Tutorials are read by beginners who are not necessarily familia…
I would go as far as to say short flags should never be shared or saved (besides man pages or similar). Long flags help anyone who needs to review something in the future, even the author. Perfect for scripts of all sorts, tutorials, anything checked into git, etc.
Remove-Item -Path X:\test\ -Recurse -Force
del X:\test -rec -forRe: Server Setup Basics for Self Hosting
#67At the end of the article, there's a link to a script[1] that does the steps covered in the article. That got me thinking: how do other self-hosters/homelabbers here go about automating their server setups? None/purely manual? One big shell script? Multiple scripts wrapped in a Makefile (or justfile, or other command runner)? More enterprisey provisioning/automation tools like Ansible, Puppet, etc.? [1] https://git.s…
It’s like Ansible, but you write Python directly instead of a YAML DSL. Code reuse is as simple as writing modules, importing them, and calling whatever functions you’ve written in normal Python.
I find it almost as easy as writing a shell script, but with most of the advantages of Ansible like idempotency and a post-run status output.
Re: Server Setup Basics for Self Hosting
#68Love seeing devops post on HN. Wish it included server monitoring as a section.
From personal experience, I would just pay someone else for a SaaS monitoring solution. It will almost universally be cheaper and more reliable.
If you really wanted to run your own, Prometheus is probably the way to go. Local storage should be fine as a data store for self-hosted. Grafana can be used for dashboarding, and either Grafana or AlertManager can do the alerting component.
It’s really not all that worth it for self-hosted scale, though. Running all that in the cloud is going to cost basically the same as buying a DataDog license unless you’re at 3-ish hosts, and more than that if you’re doing clustered monitoring so you aren’t blind if your monitoring host is down.
Re: Server Setup Basics for Self Hosting
#69Especially when writing a tutorial for beginners - please use the long-form flags (e.g. sudo usermod --append --groups sudo newuser) instead of short-form flags (e.g. sudo usermod -aG sudo newuser). Short-form flags make commands look like arcane voodoo magic. They make sense only to help you save time entering commands if you know them by heart already. Tutorials are read by beginners who are not necessarily familia…
https://architecture.lullabot.com/adr/20211006-avoid-command...
Re: Server Setup Basics for Self Hosting
#70Earlier quoted context omitted.
I've just been doing ssh -v localhost echo 2>&1 | grep continue (obviously replacing "localhost" with whatever server you want, and you can put anything you want where "echo" is but that's the best no-op I've come up with)
The best no-op, if there is such a thing, is probably `:` or `true`.