Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Brand Logo

agnos.is Forums

  1. Home
  2. Selfhosted
  3. How and where should I keep backups of system configurations?

How and where should I keep backups of system configurations?

Scheduled Pinned Locked Moved Selfhosted
selfhosted
19 Posts 12 Posters 65 Views
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • S This user is from outside of this forum
    S This user is from outside of this forum
    [email protected]
    wrote on last edited by
    #1

    Sorry for adding to the massive pile of backup-related question, but I could not figure out how to manage backups from existing answers..

    I want to backup my VPS setup (think container-defining files, its volumes, and etc configs), but am unsure where to put it. Does keeping these in the VPS itself make sense? If so, how do I create and manage the backup?

    Also, I would need a remote copy - what is the good location for this? I wish I could copy to my laptop, but obviously I cannot do that automatically. Should I pay money for a backup? I want to avoid paying lots of money just for backups.
    Thanks in advance!

    P J jeena@piefed.jeena.netJ R M 6 Replies Last reply
    0
    • System shared this topic on
    • S [email protected]

      Sorry for adding to the massive pile of backup-related question, but I could not figure out how to manage backups from existing answers..

      I want to backup my VPS setup (think container-defining files, its volumes, and etc configs), but am unsure where to put it. Does keeping these in the VPS itself make sense? If so, how do I create and manage the backup?

      Also, I would need a remote copy - what is the good location for this? I wish I could copy to my laptop, but obviously I cannot do that automatically. Should I pay money for a backup? I want to avoid paying lots of money just for backups.
      Thanks in advance!

      P This user is from outside of this forum
      P This user is from outside of this forum
      [email protected]
      wrote on last edited by
      #2

      If you haven't played with Pulumi (for configuring cloud services) and Ansible (for local services, shell commands, apt installs etc) you may enjoy them as a way to capture / re-apply configuration.

      1 Reply Last reply
      0
      • S [email protected]

        Sorry for adding to the massive pile of backup-related question, but I could not figure out how to manage backups from existing answers..

        I want to backup my VPS setup (think container-defining files, its volumes, and etc configs), but am unsure where to put it. Does keeping these in the VPS itself make sense? If so, how do I create and manage the backup?

        Also, I would need a remote copy - what is the good location for this? I wish I could copy to my laptop, but obviously I cannot do that automatically. Should I pay money for a backup? I want to avoid paying lots of money just for backups.
        Thanks in advance!

        J This user is from outside of this forum
        J This user is from outside of this forum
        [email protected]
        wrote on last edited by
        #3

        I'd get familiar with deploying these with some infrastructure-as-code tools, and keep a git repo. Ansible is pretty easy to get started with.

        1 Reply Last reply
        0
        • S [email protected]

          Sorry for adding to the massive pile of backup-related question, but I could not figure out how to manage backups from existing answers..

          I want to backup my VPS setup (think container-defining files, its volumes, and etc configs), but am unsure where to put it. Does keeping these in the VPS itself make sense? If so, how do I create and manage the backup?

          Also, I would need a remote copy - what is the good location for this? I wish I could copy to my laptop, but obviously I cannot do that automatically. Should I pay money for a backup? I want to avoid paying lots of money just for backups.
          Thanks in advance!

          jeena@piefed.jeena.netJ This user is from outside of this forum
          jeena@piefed.jeena.netJ This user is from outside of this forum
          [email protected]
          wrote on last edited by
          #4

          Most of the time the VPS provider offers some backup solution. It's not only about your configuration files which can easily be recreated, but about all the user data like pictures databases, etc. Which once lost can't be recovered.

          Best practice is a 3-2-1 backup: https://www.backblaze.com/blog/the-3-2-1-backup-strategy/

          But you could back up your stuff on your laptop if you want, it's not such a bad idea actually. For that you trigger the backup script from your laptop, you can do it automatically there too. This makes sure that the laptop is on while you're doing the backup.

          The easiest way is a crown job and a bash file which runs a couple of rsync commands to get specific files and directories from the server via ssh.

          A more involved way would be a backup system like restic, which does a lot of things for you but is a bit more involved to set up.

          1 Reply Last reply
          0
          • S [email protected]

            Sorry for adding to the massive pile of backup-related question, but I could not figure out how to manage backups from existing answers..

            I want to backup my VPS setup (think container-defining files, its volumes, and etc configs), but am unsure where to put it. Does keeping these in the VPS itself make sense? If so, how do I create and manage the backup?

            Also, I would need a remote copy - what is the good location for this? I wish I could copy to my laptop, but obviously I cannot do that automatically. Should I pay money for a backup? I want to avoid paying lots of money just for backups.
            Thanks in advance!

            R This user is from outside of this forum
            R This user is from outside of this forum
            [email protected]
            wrote on last edited by
            #5

            Ansible if you want to do it the right way.

            Or keep all of your configs in one tree and use syncthing on it If you want to phone it in. Turn on versioning call it a night.

            S 1 Reply Last reply
            0
            • S [email protected]

              Sorry for adding to the massive pile of backup-related question, but I could not figure out how to manage backups from existing answers..

              I want to backup my VPS setup (think container-defining files, its volumes, and etc configs), but am unsure where to put it. Does keeping these in the VPS itself make sense? If so, how do I create and manage the backup?

              Also, I would need a remote copy - what is the good location for this? I wish I could copy to my laptop, but obviously I cannot do that automatically. Should I pay money for a backup? I want to avoid paying lots of money just for backups.
              Thanks in advance!

              M This user is from outside of this forum
              M This user is from outside of this forum
              [email protected]
              wrote on last edited by
              #6
              1. Create git repo
              2. Put all config in git repo
              3. Create repo on codeberg
              4. Clone git repo to both VPS and laptop

              No extra money needed

              australiansimon@lemmy.worldA T S 3 Replies Last reply
              0
              • M [email protected]
                1. Create git repo
                2. Put all config in git repo
                3. Create repo on codeberg
                4. Clone git repo to both VPS and laptop

                No extra money needed

                australiansimon@lemmy.worldA This user is from outside of this forum
                australiansimon@lemmy.worldA This user is from outside of this forum
                [email protected]
                wrote on last edited by
                #7

                A guide for this would be amazing. Bookmarking to later chatGPT it.

                M fenndev@leminal.spaceF 2 Replies Last reply
                0
                • australiansimon@lemmy.worldA [email protected]

                  A guide for this would be amazing. Bookmarking to later chatGPT it.

                  M This user is from outside of this forum
                  M This user is from outside of this forum
                  [email protected]
                  wrote on last edited by
                  #8

                  https://docs.codeberg.org/getting-started/first-repository/

                  Follow this, should suffice

                  australiansimon@lemmy.worldA 1 Reply Last reply
                  0
                  • M [email protected]

                    https://docs.codeberg.org/getting-started/first-repository/

                    Follow this, should suffice

                    australiansimon@lemmy.worldA This user is from outside of this forum
                    australiansimon@lemmy.worldA This user is from outside of this forum
                    [email protected]
                    wrote on last edited by
                    #9

                    I was more thinking the config part to git.

                    remotelove@lemmy.caR 1 Reply Last reply
                    0
                    • S [email protected]

                      Sorry for adding to the massive pile of backup-related question, but I could not figure out how to manage backups from existing answers..

                      I want to backup my VPS setup (think container-defining files, its volumes, and etc configs), but am unsure where to put it. Does keeping these in the VPS itself make sense? If so, how do I create and manage the backup?

                      Also, I would need a remote copy - what is the good location for this? I wish I could copy to my laptop, but obviously I cannot do that automatically. Should I pay money for a backup? I want to avoid paying lots of money just for backups.
                      Thanks in advance!

                      J This user is from outside of this forum
                      J This user is from outside of this forum
                      [email protected]
                      wrote on last edited by
                      #10

                      Look at tools like kopia and restic. Depending on how much data you have, it should be relatively cheap to back up to backblaze b2.

                      1 Reply Last reply
                      0
                      • australiansimon@lemmy.worldA [email protected]

                        A guide for this would be amazing. Bookmarking to later chatGPT it.

                        fenndev@leminal.spaceF This user is from outside of this forum
                        fenndev@leminal.spaceF This user is from outside of this forum
                        [email protected]
                        wrote on last edited by
                        #11

                        Please don't use AI for simple things like this.

                        The Odin Project has a tutorial on Git Basics and a guide on Setting Up Git. The instructions are roughly the same whether on Github, Codeberg, etc.

                        Once you have the repository, it's as simple as:

                        git add .
                        git commit -m "Updated config"
                        git push origin main
                        
                        K 1 Reply Last reply
                        0
                        • australiansimon@lemmy.worldA [email protected]

                          I was more thinking the config part to git.

                          remotelove@lemmy.caR This user is from outside of this forum
                          remotelove@lemmy.caR This user is from outside of this forum
                          [email protected]
                          wrote on last edited by
                          #12

                          That's what you just got shown: Shove the configgy bits into Git.

                          australiansimon@lemmy.worldA 1 Reply Last reply
                          0
                          • remotelove@lemmy.caR [email protected]

                            That's what you just got shown: Shove the configgy bits into Git.

                            australiansimon@lemmy.worldA This user is from outside of this forum
                            australiansimon@lemmy.worldA This user is from outside of this forum
                            [email protected]
                            wrote on last edited by
                            #13

                            I was hoping for a guide to capture said configs with a recommended subset. Not instructions for using git.

                            So no the guides don't help with that.

                            1 Reply Last reply
                            1
                            0
                            • M [email protected]
                              1. Create git repo
                              2. Put all config in git repo
                              3. Create repo on codeberg
                              4. Clone git repo to both VPS and laptop

                              No extra money needed

                              T This user is from outside of this forum
                              T This user is from outside of this forum
                              [email protected]
                              wrote on last edited by
                              #14

                              Make sure to not check in secrets in plaintext. git crypt is one way to encrypt secrets before checking them in.

                              M 1 Reply Last reply
                              1
                              0
                              • M [email protected]
                                1. Create git repo
                                2. Put all config in git repo
                                3. Create repo on codeberg
                                4. Clone git repo to both VPS and laptop

                                No extra money needed

                                S This user is from outside of this forum
                                S This user is from outside of this forum
                                [email protected]
                                wrote on last edited by
                                #15

                                Codeberg sounds like a good way! I was concerned about server config being stored on self-hosted forgejo (which is configured by the very server config), turns out that need not be the case.

                                1 Reply Last reply
                                1
                                0
                                • fenndev@leminal.spaceF [email protected]

                                  Please don't use AI for simple things like this.

                                  The Odin Project has a tutorial on Git Basics and a guide on Setting Up Git. The instructions are roughly the same whether on Github, Codeberg, etc.

                                  Once you have the repository, it's as simple as:

                                  git add .
                                  git commit -m "Updated config"
                                  git push origin main
                                  
                                  K This user is from outside of this forum
                                  K This user is from outside of this forum
                                  [email protected]
                                  wrote on last edited by
                                  #16

                                  Please don't use AI for simple things like this.

                                  Simple things seems like the best use of AI

                                  1 Reply Last reply
                                  1
                                  1
                                  • R [email protected]

                                    Ansible if you want to do it the right way.

                                    Or keep all of your configs in one tree and use syncthing on it If you want to phone it in. Turn on versioning call it a night.

                                    S This user is from outside of this forum
                                    S This user is from outside of this forum
                                    [email protected]
                                    wrote on last edited by
                                    #17

                                    Thanks! I gotta get my hands on Ansible, was reluctant as I've heard it can be complicated. Should see myself!

                                    R 1 Reply Last reply
                                    1
                                    0
                                    • T [email protected]

                                      Make sure to not check in secrets in plaintext. git crypt is one way to encrypt secrets before checking them in.

                                      M This user is from outside of this forum
                                      M This user is from outside of this forum
                                      [email protected]
                                      wrote on last edited by
                                      #18

                                      I suggest SOPS

                                      1 Reply Last reply
                                      1
                                      0
                                      • S [email protected]

                                        Thanks! I gotta get my hands on Ansible, was reluctant as I've heard it can be complicated. Should see myself!

                                        R This user is from outside of this forum
                                        R This user is from outside of this forum
                                        [email protected]
                                        wrote on last edited by
                                        #19

                                        Ansible's not all that bad. The alternatives are far more complicated.

                                        Jeff geerling has a bunch of videos on ansible 101.

                                        1 Reply Last reply
                                        1
                                        0
                                        • System shared this topic on
                                        Reply
                                        • Reply as topic
                                        Log in to reply
                                        • Oldest to Newest
                                        • Newest to Oldest
                                        • Most Votes


                                        • Login

                                        • Login or register to search.
                                        • First post
                                          Last post
                                        0
                                        • Categories
                                        • Recent
                                        • Tags
                                        • Popular
                                        • World
                                        • Users
                                        • Groups