Reading earlier comments in this community made me consider documenting the workings of my homelab to some extent, ie. docker configuration, credentials, ports and links of my services. I’ve tried to make it consistent and organised but it still feels half baked and insufficient. Everyone suggests documenting everything you do in your homelab but don’t state how. Since I’ve hardly had experience running my own server, I would really appreciate observing the blueprint of some other fellow selfhoster for copying or taking inspiration from rather than considering documentation to be ‘left as an exercise for the reader’.

Edit: I already have a note-taking solution with me. What I wish to ask is to know what needs to be documented and what the structure of the documentation should be to accommodate the information.

  • confusedpuppy@lemmy.dbzer0.com
    link
    fedilink
    English
    arrow-up
    4
    ·
    5 hours ago

    I have two systems that sort of work together.

    The first system involves a bunch of text files for each task. OS installation, basic post OS installation tasks and a file for each program I add (like UFW, apparmor, ddclient, docker and so on). They basically look like scripts with comments. If I want to I can just copy/paste everything into a terminal and reach a a specific state that I want to be at.

    The second system is a sort of “skeleton” file tree that only contains all the files that I have added or modified.

    Here's an example of what my server skeleton file tree looks like
    .
    ├── etc
    │   ├── crontabs
    │   │   └── root
    │   ├── ddclient
    │   │   └── ddclient.conf
    │   ├── doas.d
    │   │   └── doas.conf
    │   ├── fail2ban
    │   │   ├── filter.d
    │   │   │   └── alpine-sshd-key.conf
    │   │   └── jail.d
    │   │       └── alpine-ssh.conf
    │   ├── modprobe.d
    │   │   ├── backlist-extra.conf
    │   │   └── disable-filesystems.conf
    │   ├── network
    │   │   └── interfaces
    │   ├── periodic
    │   │   └── 1min
    │   │       └── dynamic-motd
    │   ├── profile.d
    │   │   └── profile.sh
    │   ├── ssh
    │   │   └── sshd_config
    │   ├── wpa_supplicant
    │   │   └── wpa_supplicant.conf
    │   ├── fstab
    │   ├── nanorc
    │   ├── profile
    │   └── sysctl.conf
    ├── home
    │   └── pi-user
    │       ├── .config
    │       │   └── ash
    │       │       ├── ashrc
    │       │       └── profile
    │       ├── .ssh
    │       │   └── authorized_keys
    │       ├── .sync
    │       │   ├── file-system-backup
    │       │   │   ├── .sync-server-fs_01_root
    │       │   │   └── .sync-server-fs_02_boot
    │       │   └── .sync-caddy_certs_backup
    │       ├── .nanorc
    │       └── .tmux.conf
    ├── root
    │   ├── .config
    │   │   └── mc
    │   │       └── ini
    │   ├── .local
    │   │   └── share
    │   │       └── mc
    │   │           └── history -> /dev/null
    │   ├── .ssh
    │   │   └── authorized_keys
    │   ├── scripts
    │   │   ├── automated-backup
    │   │   └── maintenance
    │   ├── .ash_history -> /dev/null
    │   └── .nanorc
    ├── srv
    │   ├── caddy
    │   │   ├── Caddyfile
    │   │   ├── Dockerfile
    │   │   └── docker-compose.yml
    │   └── kiwix
    │       └── docker-compose.yml
    └── usr
        └── sbin
            ├── containers-down
            ├── containers-up
            ├── emountman
            ├── fs-backup-quick
            └── rtransfer
    

    This is useful to me because I can keep track of every change I make. I even have it set up so I can use rsync to quickly chuck all the files into place after a fresh install or after adding/modifying files.

    I also created and maintain a “quick install” guide so I can install a fresh OS, rsync all the modified files from my skeleton file tree into place, then run through all the commands in my quick install guide to get myself back to the same state in a minimal amount of time.