this post was submitted on 30 Apr 2024
82 points (97.7% liked)

Selfhosted

39435 readers
1 users here now

A place to share alternatives to popular online services that can be self-hosted without giving up privacy or locking you into a service you don't control.

Rules:

  1. Be civil: we're here to support and learn from one another. Insults won't be tolerated. Flame wars are frowned upon.

  2. No spam posting.

  3. Posts have to be centered around self-hosting. There are other communities for discussing hardware or home computing. If it's not obvious why your post topic revolves around selfhosting, please include details to make it clear.

  4. Don't duplicate the full text of your blog or github here. Just post the link for folks to click.

  5. Submission headline should match the article title (don’t cherry-pick information from the title to fit your agenda).

  6. No trolling.

Resources:

Any issues on the community? Report it using the report flag.

Questions? DM the mods!

founded 2 years ago
MODERATORS
 

Hello, I have recently been seeing a boom in people using ansible for automating setting up vps's, services, ...

Is it worth it to learn ansible to do also automate the way I setup everything, or is a bash script good enough ( I know some bash scripting but ansible seems like it could be more worth the time to learn )?

you are viewing a single comment's thread
view the rest of the comments
[–] [email protected] 1 points 7 months ago (1 children)

Luckilly no, just self interest.

[–] [email protected] 3 points 7 months ago (1 children)

I guess it depends what you're in to but it doesn't make much sense for me.

Most everything I do on servers now is in docker containers, and I back up the compose files and data from those so they can be deployed to a new server pretty easily.

Migrating between servers only happens once every several years. I feel like managing an ansible config would just be an additional layer of complexity rather than making it easier. Their isn't much configuration outside of docker in my case anyway.

[–] [email protected] 1 points 7 months ago* (last edited 7 months ago) (1 children)

I tend to grow my fleet of servers every couple months, and that requires me to once again setup everything from the beginning, settings, sshd, update debian if old version, new user for ssh, docker/podman, ...

Quite literally added new vps to my fleet yesterday and spent 4 hourson setting all that up, when it could have been a simple ansible script.

[–] [email protected] 2 points 7 months ago (1 children)

Then yes, learning Ansible is a good way to have base OS settings for your systems. I love that it's agentless - works over SSH.

The ugly part is that they keep updating it in a backwards incompatible way. In one version the paramerer is called "file" and in another it's "dest", they pull shit like this and don't provide a tool to update playbooks automatically.

But updating is rather optional.

[–] [email protected] 1 points 7 months ago

Sed comes into play there, or :%s in vim, whichever you prefer ;)