I set up a new home server recently using containerized services, and I wanted to share what I learned. Nothing here is revolutionary, but this is the type of resource I wish I had when I started.

I’m open to feedback on what I could have done better!

  • psmt@lemmy.pcft.eu
    link
    fedilink
    English
    arrow-up
    4
    ·
    1 year ago

    Great post, thanks for sharing 👍

    I would suggest to give Ansible a try, it would make it really easy to deploy a new service with all required users and config.

  • skilltheamps@feddit.de
    link
    fedilink
    English
    arrow-up
    3
    arrow-down
    1
    ·
    1 year ago

    Do you do some sort of versioning/snapshotting of your services? I’m on the compose route as well, and have one btrfs subvolume per service that holds the compose.yml and all bind-mounted folders for perstistent data. That again gets regularly snapshotted by snapper.

    What leaves me a bit astounded is, that nobody seems to version the containers they are running. But without that, rolling back if something breaks might become a game of guessing the correct container version. I started building a tool that snapshots a service, then rewrites the image: in compose.yml to reflect what ever the current :latest tag resolves to. Surprisingly, there doesn’t seem to be an off-the-shelf solution for that…

    • NewDataEngineer@lemmy.world
      link
      fedilink
      English
      arrow-up
      1
      ·
      1 year ago

      How do you do that? I’m building a similar system now that automatically updates my containers. I’ve played around with the API and I can see which versions are attached to the latest sha265, but I can’t find a way to automatically tell which version it is. Especially when the same sha is linked to multiple versions

  • Decronym@lemmy.decronym.xyzB
    link
    fedilink
    English
    arrow-up
    1
    ·
    edit-2
    1 year ago

    Acronyms, initialisms, abbreviations, contractions, and other phrases which expand to something larger, that I’ve seen in this thread:

    Fewer Letters More Letters
    Git Popular version control system, primarily for code
    SSO Single Sign-On
    VPN Virtual Private Network
    VPS Virtual Private Server (opposed to shared hosting)

    4 acronyms in this thread; the most compressed thread commented on today has 11 acronyms.

    [Thread #76 for this sub, first seen 23rd Aug 2023, 18:55] [FAQ] [Full list] [Contact] [Source code]

  • VelociCatTurd@lemmy.world
    link
    fedilink
    English
    arrow-up
    1
    ·
    1 year ago

    I have recently done something very similar though I did use Docker. Instead of VPN in the future, have you seen cloudflare tunnels? They are awesome, you do not have to expose any ports on your network and you can authenticate users with SSO. Also, not sure if it’s possible with Podman but I was able to get my Caddy setup so that the caddyfile is created and maintained automagically using a plugin.

    • Melmi@lemmy.blahaj.zone
      link
      fedilink
      English
      arrow-up
      5
      ·
      edit-2
      1 year ago

      I find it disappointing that everyone’s first suggestion in the selfhosted community is Cloudflare. It seems to run counter to the spirit of selfhosting to hand off the last part to the giant corporation that controls 90% of the Internet.

      Most of what Cloudflare does—if it’s necessary at all—can be replicated with a cheap (or free) VPS sitting in front of your network on a VPN, and the remainder doesn’t matter for most selfhosted use cases.

    • zerodawn@leaf.dance
      link
      fedilink
      English
      arrow-up
      4
      ·
      1 year ago

      Not OP, i’ve heard nothing but good things about cloudflare tunnels but for me they have two major drawbacks. The first is you can’t use them for a self hosted media server such as jellyfin as it violates their terms of service. The second is you have to trust them with all your traffic. Now i have no reason to think they would do anything nefarious but i’m at the point in my threat model journey that the less i trust in any corporations hands the better. Just my two cents.