coolneng
97a5f43206
Flake lock file updates: • Updated input 'agenix': 'github:ryantm/agenix/13ac9ac6d68b9a0896e3d43a082947233189e247' (2023-11-29) → 'github:ryantm/agenix/417caa847f9383e111d1397039c9d4337d024bf0' (2023-12-24) • Updated input 'agenix/darwin': 'github:lnl7/nix-darwin/87b9d090ad39b25b2400029c64825fc2a8868943' (2023-01-09) → 'github:lnl7/nix-darwin/4b9b83d5a92e8c1fbfd8eb27eda375908c11ec4d' (2023-11-24) • Updated input 'agenix/home-manager': 'github:nix-community/home-manager/32d3e39c491e2f91152c84f8ad8b003420eab0a1' (2023-04-22) → 'github:nix-community/home-manager/3bfaacf46133c037bb356193bd2f1765d9dc82c1' (2023-12-20) • Added input 'agenix/systems': 'github:nix-systems/default/da67096a3b9bf56a91d16901293e51ba5b49a27e' (2023-04-09) • Updated input 'nixpkgs': 'github:NixOS/nixpkgs/933d7dc155096e7575d207be6fb7792bc9f34f6d' (2023-12-02) → 'github:NixOS/nixpkgs/c1be43e8e837b8dbee2b3665a007e761680f0c3d' (2024-01-05) |
||
---|---|---|
modules | ||
scripts | ||
secrets | ||
well-known/matrix | ||
.dir-locals.el | ||
LICENSE.md | ||
Makefile | ||
README.org | ||
configuration.nix | ||
flake.lock | ||
flake.nix |
README.org
NixOS Server
Configuration files for my personal server, powered by NixOS.
Modules
The configuration is sliced into different files, per category:
- ZFS pool configuration: hardware-configuration.nix
- Network configuration: networking.nix
- Synchronization and backup services: datasync.nix
- Web services and reverse proxy: webstack.nix
- Development tools: devops.nix
- Smartd: monitoring.nix
- Systemd services and timers: periodic.nix
- Curated articles: information.nix
All the modules are imported in configuration.nix
Installation
- Download the sdcard image
- Use initial config file
cp install.nix configuration.nix
- Move the repo to the server and the agenix key
scp -r Projects/zion zion:/home/nixos/system
scp .ssh/zion root@zion:/etc/ssh/id_ed25519
- Mount the firmware partition
mount /dev/mmcblk1p1 /boot
- Rebuild the system using Flakes
nix-shell -p git
sudo nixos-rebuild switch --flake /home/nixos/system#zion
- Restore the SQL databases
gunzip -c /vault/backups/zion/databases/all.sql.gz | psql -U postgres