First my specific questions, down below more info:

  • how do you use ansible? Is there a good source for roles or playbooks to set up services? I feel like ansible is 30% more headache right now during config.
  • how do you deal with motivation loss?
  • how do you deal with the overwhelming amount of choices and information and disciplines (networking, storage, VMS, Linux…) that comes with selfhosting?
  • how do you find the sweetspot between ease of use, ease of set up, security, redundancy? I feel like I am maybe too pranaoid to loose my data again (dropped a hard drive many years back, I lost all of my projects)
  • maybe overall, how do you manage your perfectionism?

Thanks a lot! I hope you have some insights for me.


More info

Soo I have a motivational push to work on my server every few months for a few weeks or months. I always make progress and I feel like I landed on a good solution by now. Its the third time I redid my setup, everytime I got closet to what feels like the perfect setup for me.

I have a vps for headscale, a home server with proxmox for the rest.

Last push I switched from manually configuring and documenting to ansible. I like ansible, but its also a pain and not as fast to set up my server as just installing it and fiddeling around manually until it works.

My problem is: I want to do it right, so my server is robut with enough redundancy to move all my cloud stuff to it. But I am still kind of a noob and still learning and figuring things out.

My fear is, that if i don’t document well or not use ansible, I will be hating my life once my server dies and I have to restore my data and also set um my services again in a few years.

So ansible seems like the only valid choice here, together with proxmox to be as flexible and future proof. But I am burnt out again and lost Motivation even though I am close to my first goals and running services.

Thank you for reading :)

  • SayCyberOnceMore@feddit.uk
    link
    fedilink
    English
    arrow-up
    3
    ·
    3 hours ago

    You’re doing fine.

    After seeing someone at work burnout, I’ll offer this advice:

    Find what you enjoy doing and do nothing more (today). Itch only 1 scratch at a time.

    As an analogy - consider you’ve moved into a newly built house and have an empty garden. No-one would expect you to create that perfectly first time around. Esp. in 1 weekend. It needs time to grow. Some things will need cutting down, some things will need moving. Animals will crap on it.

    I think you’re trying to make it perfect, first time around. Perhaps as a fear of doing it “wrong”.

    There is no wrong, it’s all a learning experience, doing things good enough for now and improving / breaking things later.

    Ensure you know how to backup your files (3-2-1 rule) and the rest doesn’t matter.

    I’ve re-written my ansible scripts a few times, but over months and years as I’ve learned what works best for my system.

    For example, I had 1 complete script for each device. I can wipe the device (get it back on the network) and rebuild with no effort…

    … then I realised that most of the scripts had very similar parts to tweak SSH and other settings, so then I learned how to call scripts from within scripts, which also meant using variables (facts) to work out if this is a 32b or 64b RasPi (for example)

    That probably took 3 months

    But I enjoy sitting in my garden and looking at it…

    • Matt The Horwood
      link
      fedilink
      English
      arrow-up
      2
      ·
      3 hours ago

      I would echo that, I’ve been a generalist computer whatnot for over 10 years. I have had to learn to network, virtual network with VMware. Manage Linux servers, then virtual servers. Switch from VMware to aws and understand basic terraform, with ansible learning as well.

      Where I work we are on ansible repo 3 I think, as we have matured in how we use it and what works and what doesn’t.

      When homelabing, you get to be all the things a big company would have job roles for.

  • aarch0x40@piefed.social
    link
    fedilink
    English
    arrow-up
    35
    ·
    14 hours ago

    It sounds like you’re trying to learn but have an “all or nothing” mentality to going about it. Nothing is mastered all of a sudden and expecting mastery out the gate is a recipe for burn out. If you’re goal is absolute perfection then you’ll never even start.

    Go through the online docs and training resources first to gain an understanding of how to assemble playbooks without a direct implementation target attached.

    Once you have a sense of what Ansible is and what it can do for you, pick something small to do for yourself. For example, create a playbook that sets up nginx for a single purpose.  When there are a 100 different ways to do something, you’ll never do it right. You’ll do it acceptably, then you’ll do it again better and then you’ll do it again more flexibly, etc.  If you know or pick up Python then you’ll start being able to dive into custom modules and plugins.

    A toolkit is something you build over time. You build it over time because it’s impossible to know what you’ll need before you start. If you do end up pulling together a toolkit that you think it appropriate and complete before you start working then you’ll have a mess of configurations that are not applicable and mostly inappropriate that you’ll end up debugging forever.

    Start small. Start where you are.

  • farcaller@fstab.sh
    link
    fedilink
    English
    arrow-up
    15
    arrow-down
    1
    ·
    edit-2
    4 hours ago

    My fear is, that if i don’t document well or not use ansible, I will be hating my life once my server dies and I have to restore my data and also set um my services again in a few years.

    I’ve been there plenty of times, you’re not alone. There are two solutions to that problem, really, and it boils down to the classic pet vs cattle.

    1. Everything is a pet

    Pets mean you care about every server. If it breaks, it’s cheaper for you to fix it than redeploy. The overwhelming majority of your setup will be pets. Why? It’s simpler. Things don’t break that often, and when they do, it’s okay to be low-effort in fixing them.

    Write docs for yourself, even if it’s just notes on the sequences of commands to run to redeploy things. You will thank yourself when the server finally dies in two years and you have notes on how to bring everything back.

    1. Everything is a cattle

    Cattle means there’s no difference between server A and B. Everything is replaceable. Ultimately, whatever you run can run to the same extent in AWS, your basement NAS, or on your desk PC.

    Cattle is also a lot of work. You will learn an excruciating amount of things about storage, networking, visualisation, workload scheduling, and such. And it’s easy to be demotivated because of how much there is to learn.

    So take it easy. Concur that your hobby world is full of pets, but learn how to do the cattle approach at your leisure. You’ll realise that in every practical cattle setup, there are still pets, and that automating yourself from complexity only means you add layers of it somewhere else.

    • timmytbt@sh.itjust.works
      link
      fedilink
      English
      arrow-up
      7
      ·
      11 hours ago

      This is brilliant: “automating yourself from complexity only means you add layers of somewhere else”. Need to tattoo this on my forearm!

  • [object Object]@lemmy.world
    link
    fedilink
    English
    arrow-up
    5
    ·
    11 hours ago

    My motivation to use Ansible is fueled by disdain for manual non-scriptable configuration. I’ve had to use Windows for a couple years lately, and the absence of programmatic access to many things annoyed me to no end.

    Now, I get up in the morning and look to the east. I salute the sun and thank the fate for the chance to do proper configuration again. I don’t wade through dialogs for hours anymore. I don’t lose track of things that I’ve changed somewhere sometime. I’ll learn what the hell the difference between dconf and gsettings is, just to use one of them for all my desktop settings forever. I will have this config for years to come, and I will put more things in it bit by bit.

    Now, if Ansible’s config language wasn’t a naive reinvention of Lisp, that would be great.

  • Jade@programming.dev
    link
    fedilink
    English
    arrow-up
    2
    ·
    9 hours ago

    My personal selfhosting repo is just about 2 years old with 750 commits now, and probably more than 60 containers running. It’s not because of one great effort or design or anything, just setting up a service or two when I find it interesting every few weeks, and trying to make all my setup consistent. Almost everything is deployed as a container run by Podman quadlets, files mounted in /var/opt, config etc copied into place by an ansible script. But not everything, sometimes getting it working was easier without the sensible or I needed to do some funny networking.

    TLDR: Coming back again later, and making that easier.

  • synae[he/him]@lemmy.dbzer0.com
    link
    fedilink
    English
    arrow-up
    7
    ·
    13 hours ago

    My successful path for homelab stuff is to use kubernetes (k3s locally and digital ocean DOKS for cloud resources) with argocd and gitops. Everything I change is via a git commit+push so I can always rollback, and if this machine dies, once I replace/repair the hardware I can pull all backed up content from object storage, install K3s again, reconfigure the authentication for Argocd, and it will repopulate all the running services.

    I am absolutely not saying this is the right path for you as I came into nearly all my modern knowledge through my career, but it is a path

  • frongt@lemmy.zip
    link
    fedilink
    English
    arrow-up
    6
    ·
    13 hours ago

    I just aim for “good enough”. Does it work, does it meet my needs? That’s good enough, even if it isn’t exactly the right way.

    Like right now I have a system that needs manual intervention if I shut it down, or it’ll come back up non-functional. But it works well enough so I’ll just fix that eventually. I like to spend my free time doing more social or productive stuff.

  • exu@feditown.com
    link
    fedilink
    English
    arrow-up
    4
    ·
    13 hours ago
    • how do you use ansible? Is there a good source for roles or playbooks to set up services? I feel like ansible is 30% more headache right now during config.

    I write my own playbooks and roles, but often I can just copy paste an existing setup and use it for a new service. For example containers, you can probably write one role once, copy it and modify some variables to set up another container service.
    For stuff where there are well maintained community roles (e.g. community.zabbix) just use those and configure with variables.

    • how do you deal with motivation loss?

    I just don’t work on a part I don’t want to do atm. It’s supposed to mostly be a hobby and as long as my services I care about are running it’s fine.

    • how do you deal with the overwhelming amount of choices and information and disciplines (networking, storage, VMS, Linux…) that comes with selfhosting?

    I’m on my 2.5th setup now, just choose something and see if it works. If not, see how much it bothers you and what parts you want to migrate.
    I’m a big fan of VMs, so I’m using XCP-ng. IMO this makes testing and backups very easy, I just take a snapshot and figure stuff out, no big deal if it breaks.

    • how do you find the sweetspot between ease of use, ease of set up, security, redundancy? I feel like I am maybe too pranaoid to loose my data again (dropped a hard drive many years back, I lost all of my projects)

    You’re better than 95% of people just by thinking about this. For backups, identify which data you want to back up and do that. If you don’t want to deal with Ansible right now, just set something up manually and automate it later (paste your commands into a readme for reference)
    For me, I make sure to backup my Nextcloud data. That included personal photos, files and other hard to replace stuff. Other than that I have daily VM backups to a Hetzner storage box and my NAS. I don’t backup my media on Jellyfin, that’s just not as important.
    VMs also make it easy to replace your host. Just install the hypervisor on a new server and restore VMs to it.

    • maybe overall, how do you manage your perfectionism?

    I guess I’m not a perfectionist. It took me multiple months and monetary incentive (avoid renting two servers) to migrate from my Debian single host setup to VMs years ago.
    Some of my Ansible playbooks are “version 1”, where I didn’t know what I was doing. I’m on version 3 now. They still work, I even use some of them occasionally, just haven’t taken the time to migrate them yet.
    Maybe you can take a similar approach with some of your services that aren’t that essential and spread out the work more so you can enjoy it when you want to.

  • tobz619@lemmy.world
    link
    fedilink
    English
    arrow-up
    5
    arrow-down
    2
    ·
    13 hours ago

    Don’t use Ansible and use Nix instead.

    Seriously though give yourself time and a solid goals you want to achieve, it’ll take time and it’ll be worth it as

    • rtxn@lemmy.world
      link
      fedilink
      English
      arrow-up
      6
      ·
      9 hours ago

      Is this what normies feel like when Linux users tell them to just use Linux? I have some apologies to make.

      • Sightline@lemmy.world
        link
        fedilink
        English
        arrow-up
        1
        ·
        9 hours ago

        Nix has issues, personally I’m using an immutable distro. Right now I can go upstairs and yank the power and it’ll boot right back up like nothing ever happened.

        I want something rock solid, and neither Ansible or NixOS provide that. Here’s the article that I took inspiration from: https://words.filippo.io/frood/

        • i_am_not_a_robot@discuss.tchncs.de
          link
          fedilink
          English
          arrow-up
          2
          arrow-down
          1
          ·
          7 hours ago

          An immutable distro… like NixOS? Or do you mean your root filesystem is immutable? NixOS can do that too. You could normally mount your nix store as readonly and remount rw during updates if you really care about filesystem immutability, or use some snapshot system if you’re paranoid about adding new files to the store corrupting other files already in the store during an update.

          The nixpkgs VM creation module, which I’ve never seen documentation for, has a mode where it generates a kernel, initrd, kernel command line, and erofs image containing a prepopulated /nix directory and that’s enough to boot the VM.

          Ansible is disappointing as an IAC tool. It’s good for doing things, but it’s not good for converging systems to a desired state. Too often you end up with playbooks that are not idempotent or rely on something that was done during a previous execution of the playbook or just don’t do something that was done by a previous version, and then unless you are constantly recreating your systems you won’t notice until it’s a problem and you can’t get your system back.

          • Sightline@lemmy.world
            link
            fedilink
            English
            arrow-up
            1
            ·
            edit-2
            16 minutes ago

            I mean my root filesystem is immutable, it runs completely in RAM (squashfs). After trying NixOS and seeing that article I linked about an immutable Alpine NAS I decided to try it for myself. I found it easier to just customize the Arch ISO builder and generate/update images as needed versus following the article exactly, I’m also not familiar with Alpine itself.

            Packages aren’t pinned in my Arch image and it’s not 100% deterministic, but that’s fine it’s a risk I’m willing to take. So far it’s been absolutely rock solid, lean and easy to manage.

            Also, I found NixOS annoying because:

            1. the language

            2. the config application (I forget the command) was doing god knows what behind the scenes. My needs aren’t that complicated, I’m comfortable with just manually setting things up and locking that in by generating an Arch image. It’s way easier.

  • nullpotential@lemmy.dbzer0.com
    link
    fedilink
    English
    arrow-up
    3
    ·
    13 hours ago

    I’ve just been using debian with docker compose for over two years, and everything just works. The only reason I would have to use ansible at this point would be if I wanted to replicate the setup.