An Ansible-powered homelab setup containing a git server, and probably some other services in the future.
Find a file
2025-07-27 22:11:13 +02:00
.vscode implement REUSE compliant licensing 2025-06-30 13:33:38 +02:00
group_vars support sieve block list 2025-07-27 22:06:52 +02:00
host_files change snac hostname to o-o.li 2025-07-27 22:11:13 +02:00
host_vars change snac hostname to o-o.li 2025-07-27 22:11:13 +02:00
inventory update licensing to include contact email 2025-07-09 14:04:16 +02:00
LICENSES implement REUSE compliant licensing 2025-06-30 13:33:38 +02:00
mnt update licensing to include contact email 2025-07-09 14:04:16 +02:00
roles support sieve block list 2025-07-27 22:06:52 +02:00
sandbox update licensing to include contact email 2025-07-09 14:04:16 +02:00
scripts update licensing to include contact email 2025-07-09 14:04:16 +02:00
.editorconfig update licensing to include contact email 2025-07-09 14:04:16 +02:00
.git-blame-ignore-revs update blame ignore file 2025-07-09 14:05:03 +02:00
.gitignore update licensing to include contact email 2025-07-09 14:04:16 +02:00
ansible.cfg update licensing to include contact email 2025-07-09 14:04:16 +02:00
check-connectivity.yml improve check connectivity script 2025-07-21 11:03:57 +02:00
playbook.yml add snac (fediverse) role 2025-07-21 17:19:30 +02:00
readme.md update licensing to include contact email 2025-07-09 14:04:16 +02:00
REUSE.toml update licensing to include contact email 2025-07-09 14:04:16 +02:00
synology.yml update licensing to include contact email 2025-07-09 14:04:16 +02:00

Humble homelab

Hippocratic License HL3 Please don't upload to GitHub

Servers tend to get weird over time. Hence, I maintain this overview to remind myself of all the stuff running various places. This makes it easier to get everything back up and running when the hardware eventually fails.

I also hope that sharing this can inspire others to try self-hosting as well.

This project assumes that you're familiar with Ansible. For a thorough introduction to Ansible, I can highly recommend the e-book Ansible for DevOps by Jeff Gerling.

Getting started with local development

In this project there's a sandbox/ directory which specifies a virtual machine in which we can try out our ansible roles.

Prerequisites:

  1. Run git clone git@code.on.nilsnh.no:nilsnh/humble-homelab.git to download this repo.
  2. Navigate to sub-directory sandbox/
  3. Start local Vagrant with vagrant up, it should automatically provision the sandbox/playbook.yml file.
    • Use vagrant ssh to ssh inside a running box.
    • Use vagrant provision to quickly re-run Ansible changes when developing.
    • Use vagrant destroy to fully delete box.
  4. After the initial vagrant provision, you can subsequently call ansible-playbook --become site-forgejo.yml or other playbooks for developing various roles.

☝️ This will fail if you don't have configured Ansible Vault password.

Deploying changes

  1. First ensure that you have various ansible variables correctly configured. Any secrets should be handled by Ansible Vault, see section below.
  2. Specify your target server(s) in inventory/production
  3. Call ansible-playbook --become playbook.yml.

How-to setup Raspberry Pi to use SSD storage

  1. Use Raspberry Pi Imager.
  2. Flash a new SSD
  • Use my default SSH public key.
  • Activate SSH login.
  • Skip configuring wi-fi, if you're relying on ethernet instead.

Configuring Ansible Vault and other variables

Ansible Vault lets us safely store secrets encrypted in git.

To edit Vault entries run ansible-vault edit group_vars/all/vault.yml. If you're a new user who just downloaded this repo, you should just delete the vault.yml file and re-create it using ansible-vault.

A ansible.cfg file in project root is configured to check ~/.vault_pass for Vault password.

Documentation is regrettably poor on what variables each this project's roles actually require. Nevertheless, I hope that they might be of some use to you just the same.

Licensing

This project uses REUSE Software for licensing. See LICENSES/ to see what licenses are used for this project. See the top section of individual files to learn what license they're released under, for the most part they're released under the Hippocratic 3.0 license with various provisions enabled. Consult the actual license text within LICENSE/ to see what's what. See also the REUSE.toml file(s) to review licensing for files that don't support custom headers (such as image files).

To generate a complete Software Bill of Materials (SBOM). Run pipx run reuse spdx (requires pipx).

Credit

The flower emoji comes from the openemoji project, and is licensed under CC BY-SA 4.0.