Compare commits

..
186 Commits
Author SHA1 Message Date
blake b7d27d8ea1 syncthing bullshit 2026-09-24 15:06:10 -05:00
blake 52641b8b10 change tailscale to cli via nix 2026-09-24 13:06:15 -05:00
blake 256a9684fe change tailscale to gui via nix 2026-09-24 12:58:10 -05:00
blake 6f74b4aff3 change tailscale to gui via nix 2026-09-24 12:56:14 -05:00
blake ae9a50f11e change tailscale to gui via nix 2026-09-24 12:55:38 -05:00
blake 8c9ff95e68 update hash update 2026-09-17 15:40:35 -05:00
blake b21b81caf4 updates for jellyfin 12.0 2026-09-17 15:36:06 -05:00
blake 17631704b1 switch jellyfin to unstable for 12.0 2026-09-17 15:29:34 -05:00
blake cf29da55dc add wger, prolly wont set all this up tho, its a lot 2026-09-17 12:13:11 -05:00
blake 4d512e6f6c enable status 2026-09-10 13:30:21 -05:00
blake 3dbcfe9ff1 allow the query port 2026-09-10 13:23:15 -05:00
blake d196fed0d8 add prepare for monitoring 2026-09-10 13:19:36 -05:00
blake 491721aed3 open valheim route 2026-09-10 13:08:06 -05:00
blake faceb9d0ca open valheim ports 2026-09-10 12:57:50 -05:00
blake 8832a4495b valheim ddns 2026-09-10 12:47:38 -05:00
blake 3e268f4b22 add forwards for valheim 2026-09-10 12:46:43 -05:00
blake c9d30a962c fix motd 2026-09-10 12:40:59 -05:00
blake 7176ce59d2 fix motd 2026-09-10 12:39:41 -05:00
blake 47c160200f add fix option path 2026-09-10 12:38:14 -05:00
blake 5e6d4b6344 add import 2026-09-10 12:36:09 -05:00
blake 409d84b530 add valheim to lumiose 2026-09-10 12:35:20 -05:00
blake 60e745a3d9 config valheim 2026-09-10 12:34:47 -05:00
blake c9dc8a0def init valheim 2026-09-10 12:22:13 -05:00
blake 071b6f0e66 add acrobat pro 2026-09-02 11:48:52 -05:00
blake 0d48663d81 dumb shit 2026-09-01 03:05:46 -05:00
blake c56e020dec navidrome change plugins folder 2026-09-01 02:40:53 -05:00
blake 5af6c6242b navidrome change plugins folder 2026-09-01 02:39:23 -05:00
blake 08c829a708 navidrome change plugins folder 2026-09-01 02:38:13 -05:00
blake 939fb8d96b navidrome change plugins folder 2026-09-01 02:34:16 -05:00
blake 6b43e1e1d6 navidrome change plugins folder 2026-09-01 02:26:47 -05:00
blake 8915ff714f navidrome change plugins folder, give up 2026-09-01 02:11:27 -05:00
blake ec9ba4f0e5 navidrome change plugins folder 2026-09-01 02:10:01 -05:00
blake b481fd9c6b navidrome change plugins folder 2026-09-01 02:09:21 -05:00
blake dbf21fa3e9 navidrome change plugins folder 2026-09-01 02:07:39 -05:00
blake 5c928aac70 add yt-dlp nixos 2026-09-01 01:06:37 -05:00
blake 074fec8677 fix alias 2026-08-31 22:55:27 -05:00
blake 503b850943 fix alias 2026-08-31 22:53:40 -05:00
blake eff0c765c0 fix alias 2026-08-31 22:52:30 -05:00
blake b5deb4334f fix alias add ffmpeg 2026-08-31 22:45:35 -05:00
blake 785bdc4b32 fix alias add ffmpeg 2026-08-31 22:42:04 -05:00
blake a483ea764e add yt-dlp zsh alias 2026-08-31 22:35:05 -05:00
blake f232163920 add yt-dlp zsh alias 2026-08-31 22:23:42 -05:00
blake aec377046e add yt-dlp 2026-08-31 22:16:19 -05:00
blake d22c274a52 add picard 2026-08-31 21:53:51 -05:00
blake b4ab71c8cd fix stupidity 2026-08-31 19:04:13 -05:00
blake 7dde6470a4 fix ls on macos and other nav, passwdless lf 2026-08-31 19:01:49 -05:00
blake 11ab7440fa add lidarr to mediastack import 2026-08-31 14:38:21 -05:00
blake 72107e2339 add lidar 2026-08-31 14:36:30 -05:00
blake b21eeb5b66 take down uptime-kuma public 2026-08-31 12:31:22 -05:00
blake 4b9a6bf8cc disable runescape 2026-08-31 12:00:52 -05:00
blake 7113725038 vaultwarden ssh 2026-08-31 08:48:25 -05:00
blake d9885a92d5 trying to figure out ipv6 2026-08-26 16:48:03 -05:00
blake 1138e567e6 tailscale and brew fiddling 2026-08-26 14:52:39 -05:00
blake e66dfa5d61 updates 2026/8/26 2026-08-26 13:41:12 -05:00
blake 03c1d94677 add flo 2026-08-25 23:19:30 -05:00
blake d7c8c9e6fe peazip 2026-08-25 23:17:27 -05:00
blake 4a887023b9 peazip 2026-08-25 23:16:51 -05:00
blake 4debf084fe config nextdns 2026-08-25 23:15:59 -05:00
blake b885fc14ab move timemachine back to archives 2026-08-25 17:08:29 -05:00
blake 53b2a66d8e update ddns 2026-08-25 15:01:13 -05:00
blake 38fd7ec62e add more to glance 2026-08-25 14:34:44 -05:00
blake 01906fc345 add more to glance 2026-08-25 14:32:53 -05:00
blake f45b902e58 reorganize glance 2026-08-25 13:24:35 -05:00
blake 9fa860c86c config nextdns 2026-08-25 12:56:52 -05:00
blake d9864bbebf config nextdns 2026-08-25 12:49:08 -05:00
blake 7d23d676bf add nextdns for darwin 2026-08-25 12:42:51 -05:00
blake 08fa7027d8 reorganize proxys 2026-08-25 12:29:35 -05:00
blake 3e97b5cd67 configuring navidrome 2026-08-25 10:55:58 -05:00
blake 92a71ec2ba change glance order 2026-08-25 10:43:56 -05:00
blake 9f626a0f8e add navidrome 2026-08-25 10:33:04 -05:00
blake d6c5d3ded4 add navidrome 2026-08-25 10:32:08 -05:00
blake cc76377b37 enable ssh for root 2026-08-23 14:49:55 -05:00
blake 2ada0e3e3a add trusted keys for root 2026-08-23 14:42:45 -05:00
blake 7f74cd42b4 add script 2026-08-23 13:22:46 -05:00
blake 843f85e23e add script 2026-08-23 13:21:14 -05:00
blake 54f224a598 update glance for service move 2026-08-23 12:46:19 -05:00
blake e4ebae88fe update glance for service move 2026-08-23 12:44:30 -05:00
blake 688c96ae9a update glance for service move 2026-08-23 12:43:27 -05:00
blake 9396da0b8d fin git and vaultwarden move 2026-08-23 12:32:45 -05:00
blake 4016df88a5 stop forwarding 2026-08-23 12:27:34 -05:00
blake c0b661f83c fix new git ssh 2026-08-23 12:25:04 -05:00
blake a6b7d7f318 just a whole bunch of backup changes & move pass and git to vps 2026-08-23 12:12:44 -05:00
blake 9e475209e5 rsync over ssh for homelab 2026-08-23 11:31:53 -05:00
blake 556adde3a3 add option to backup to lumiose too 2026-08-23 11:28:27 -05:00
blake 0cc81e1126 add option to backup to lumiose too 2026-08-23 11:27:59 -05:00
blake 0f0857dd7c ssh updates 2026-08-23 11:19:48 -05:00
blake 6873fe64cb ssh updates 2026-08-23 11:18:36 -05:00
blake 603fbdc9ba ssh updates 2026-08-23 11:17:24 -05:00
blake 18bfb424f5 kde config 2026-08-23 11:13:17 -05:00
blake 64e56a615e fix module name 2026-08-23 10:59:41 -05:00
blake 671f157b8d add more borg options for dbs and offsite 2026-08-23 10:42:48 -05:00
blake 9736a86d9e add more borg options for dbs and offsite 2026-08-23 10:42:16 -05:00
blake e958a81b04 cleanup and fix borg on vaniville 2026-08-23 10:35:15 -05:00
blake 88819be7e7 enable option for homelab 2026-08-23 09:03:50 -05:00
blake 288724e86c move archives user 2026-08-23 09:01:09 -05:00
blake 583c997a62 kde 2026-08-23 08:57:51 -05:00
blake c2599ae219 move archives user 2026-08-23 08:57:14 -05:00
blake b2d33de709 move archives user 2026-08-23 08:54:56 -05:00
blake e21b3e7814 kde config 2026-08-23 08:47:45 -05:00
blake ec24d8c518 kde 2026-08-23 08:36:51 -05:00
blake 5466f8eb44 enable backups test 2026-08-23 08:27:12 -05:00
blake b5b544b83f enable backups test 2026-08-23 08:26:08 -05:00
blake 966780e7c4 updates 2026-08-23 08:25:38 -05:00
blake 24d104ad60 2026-8-3 updates 2026-08-23 07:33:36 -05:00
blake 4a79e6e3a1 smb settings for nvr 2026-08-12 01:24:12 -05:00
blake a1cbc554d8 smb settings for nvr 2026-08-12 01:16:18 -05:00
blake cc4f628ea6 smb settings for nvr 2026-08-12 01:15:57 -05:00
blake 2fc89120a8 add archives user 2026-08-12 01:07:56 -05:00
blake 11d6dde229 add change nvr settings 2026-08-12 00:50:09 -05:00
blake af2fc02d97 add nvr smb share 2026-08-07 17:49:44 -05:00
blake 3382f30b9d add zygarde to ssh 2026-08-07 04:25:27 -05:00
blake 3252c941aa enable expramental event entities for thirdreality buttons 2026-08-07 03:44:33 -05:00
blake 5447afbf61 change interface 2026-08-07 01:27:21 -05:00
blake a5f624b6b7 updates 2026-08-01 09:50:26 -05:00
blake af3a35cdec finish up kiwix 2026-07-30 12:36:53 -05:00
blake 4e0c40e83b remove homebox being in media group 2026-07-30 12:21:27 -05:00
blake 6ab43ae093 init nomad 2026-07-30 12:21:03 -05:00
blake 2e3b829118 fin homebox 2026-07-29 16:37:32 -05:00
blake ed0f761f7b homebox fix description 2026-07-29 16:25:03 -05:00
blake 888946cbc2 add homebox 2026-07-29 16:23:52 -05:00
blake 9fd96c57d6 add homebox 2026-07-29 16:23:37 -05:00
blake 8d4fcda2ce clean up testing 2026-07-28 10:25:05 -05:00
blake ff4759a368 testing new ssl with sonarr 2026-07-28 09:46:58 -05:00
blake 7f1db3ec3a setup caddy for ssl via dns with cloudflare 2026-07-28 09:44:28 -05:00
blake e5b8d6eb94 setup caddy for ssl via dns with cloudflare 2026-07-28 09:38:58 -05:00
blake 67527c2ef9 setup caddy for ssl via dns with cloudflare 2026-07-28 09:38:19 -05:00
blake 9659dcf9ef setup caddy for ssl via dns with cloudflare 2026-07-28 09:36:33 -05:00
blake 79a04d45a4 update mc server monitoring name 2026-07-27 12:50:42 -05:00
blake 887b8f3953 fix title for caddy page 2026-07-27 12:05:05 -05:00
blake e36095c1d7 properly implement a toggle for the keys subdomain 2026-07-27 12:01:37 -05:00
blake f36d67b29a adjust hosts for keys 2026-07-27 12:00:37 -05:00
blake 58c7919936 properly implement a toggle for the keys subdomain 2026-07-27 11:57:24 -05:00
blake 34254ffd93 add sops for modded mc 2026-07-23 13:08:29 -05:00
blake 649de1ce1a add sops for modded mc 2026-07-23 13:05:17 -05:00
blake 3db2962b85 add sops for modded mc 2026-07-23 12:58:45 -05:00
blake a27d6b11c0 add offsite backup support to modded mc 2026-07-23 12:57:03 -05:00
blake bd37a7bbd4 update lifeboat link in glance 2026-07-23 12:22:04 -05:00
blake 7f0e96b058 updates 2026-07-23 11:36:34 -05:00
blake 776e68e1e6 server modded swap 2026-07-23 10:45:14 -05:00
blake 1ded87909f fix tailscale routing shit 2026-07-23 10:41:20 -05:00
blake 479a8b2e03 update cen-it-07 syncthing id 2026-07-22 12:45:59 -05:00
blake 1e206de4c0 rectangle to brew 2026-07-15 16:01:21 -05:00
blake df71394956 update lifeboat ip 2026-07-15 09:05:02 -05:00
blake 4c89bf0f72 updates 2026-07-14 17:20:38 -05:00
blake dd3c2f817f spelling mistake 2026-07-09 22:37:00 -05:00
blake 89ee4bdfd4 tailscale accept routes 2026-07-09 22:19:31 -05:00
blake 5746e0144f fix caddy 2026-07-02 10:22:54 -05:00
blake 7297aaa8fb apps or some shit 2026-07-02 00:16:07 -05:00
blake adec4a5c2e add snowbelle back to subnets baby 2026-07-01 23:26:21 -05:00
blake 41211b41bb fix firewall 2026-07-01 23:25:24 -05:00
blake b18c04df36 fix port 2026-07-01 23:17:50 -05:00
blake 32a5121936 update craftoria port add voicechat 2026-07-01 23:16:28 -05:00
blake 5b9d15b2ce update craftoria port add voicechat 2026-07-01 23:15:17 -05:00
blake adcdfd604c update craftoria port 2026-07-01 23:09:14 -05:00
blake a23a211d89 fix port 2026-07-01 23:06:21 -05:00
blake 78e0b6723b finish craftoria 2026-07-01 23:01:17 -05:00
blake 84ba07b035 finish craftoria 2026-07-01 23:00:47 -05:00
blake 59ac5e92d9 sort out the jar situation 2026-07-01 22:52:44 -05:00
blake 7505abb756 craftoria 2026-07-01 22:36:25 -05:00
blake 6dca018d13 craftoria 2026-07-01 22:35:38 -05:00
blake a52b181b27 craftoria 2026-07-01 22:33:32 -05:00
blake 36cf6156e1 craftoria 2026-07-01 22:32:59 -05:00
blake ae0c4a9df2 modded i guess 2026-07-01 22:30:51 -05:00
blake 9e3955a0f9 test adding gimp back, add thudnerbird 2026-06-30 09:19:04 -05:00
blake 32efe6cb40 test adding gimp back, add thudnerbird 2026-06-30 09:18:19 -05:00
blake 0ab66f480b add back unifi 2026-06-29 08:04:07 -05:00
blake e8d3dbfc74 relabel ports 2026-06-29 08:03:20 -05:00
blake 6343f90947 add open port for homekit 2026-06-28 21:50:03 -05:00
blake 1ac6fc6e66 update glance check url for shauna 2026-06-28 21:40:14 -05:00
blake 0ecbead350 reduce keepalive interval 2026-06-24 15:51:22 -05:00
blake b5fe99371f disable backups 2026-06-24 15:48:12 -05:00
blake b24a3df88c update keepalive urls 2026-06-24 15:43:17 -05:00
blake 82cb5a742c add unas to subnet router 2026-06-24 10:49:20 -05:00
blake 77067724ce set static on vpn 2026-06-23 20:55:11 -05:00
blake 182e5abbbf try and spoof mac addr on vpn 2026-06-23 20:37:52 -05:00
blake 8abbd70e3d add keepass 2026-06-23 09:01:04 -05:00
blake 39eb846407 update glance links 2026-06-22 16:44:35 -05:00
blake d47a7580ed update vaultwarden reverse proxy 2026-06-22 16:35:30 -05:00
blake e93f8cd4ee vaultwarden updates 2026-06-22 16:19:38 -05:00
blake dd3bd26b60 vaultwarden updates 2026-06-22 16:15:46 -05:00
blake 9a204bce60 vaultwarden updates 2026-06-22 16:14:18 -05:00
blake 36a6ec23b3 vaultwarden updates 2026-06-22 15:54:23 -05:00
blake 279340f744 update ssh alias, add gateway to advertise for now 2026-06-22 10:52:14 -05:00
blake b4201cfeb4 zfs aliases 2026-06-21 02:58:30 -05:00
blake f444756575 disable test msg 2026-06-20 20:46:35 -05:00
blake 6f3999c1f9 move msmtp to dedicated file 2026-06-20 20:44:09 -05:00
64 changed files with 1413 additions and 852 deletions
+7
View File
@@ -0,0 +1,7 @@
#!/usr/bin/env bash
cd /home/blake/.nix
git remote remove origin
git remote add origin ssh://gitea@git.holocron.blue:7567/blake/nix.git
git fetch
git branch --set-upstream-to=origin/trunk trunk
Generated
+104 -140
View File
@@ -106,16 +106,16 @@
"brew-src": { "brew-src": {
"flake": false, "flake": false,
"locked": { "locked": {
"lastModified": 1781226006, "lastModified": 1788591592,
"narHash": "sha256-w4ZTuOnhYiDxjaynrMTASzp802QblBWmo3wpB8wVN4Y=", "narHash": "sha256-NbwVKwKLFl0oXub7oPjvmDaOygCtV2oboeKTu4xXFTk=",
"owner": "Homebrew", "owner": "Homebrew",
"repo": "brew", "repo": "brew",
"rev": "109191be4988470b51a60a5ef1998520aa24c01b", "rev": "08e85c4e42f5d8f1ea17c36cb59cf61c2ccb26c3",
"type": "github" "type": "github"
}, },
"original": { "original": {
"owner": "Homebrew", "owner": "Homebrew",
"ref": "6.0.1", "ref": "6.0.22",
"repo": "brew", "repo": "brew",
"type": "github" "type": "github"
} }
@@ -126,11 +126,11 @@
"nixpkgs": "nixpkgs" "nixpkgs": "nixpkgs"
}, },
"locked": { "locked": {
"lastModified": 1781385969, "lastModified": 1789598303,
"narHash": "sha256-dn8GKHXb0MQWNaqBXIZIyryA6YgNZsHULHTevRfwvd4=", "narHash": "sha256-hyAB8PqtE+2NPbXqFWFOVessao4ccpsQq6hKBfZPN0w=",
"owner": "9001", "owner": "9001",
"repo": "copyparty", "repo": "copyparty",
"rev": "efa43f891b18f9e0b354ce676d3050b7690f985e", "rev": "6867ccc51181e7965445c3d158ddddf9a8fd817e",
"type": "github" "type": "github"
}, },
"original": { "original": {
@@ -277,11 +277,11 @@
"firefox-gnome-theme": { "firefox-gnome-theme": {
"flake": false, "flake": false,
"locked": { "locked": {
"lastModified": 1779670703, "lastModified": 1783570805,
"narHash": "sha256-UdfMivNMwCCqQsYDg5pSz8X2IOaOrIZLIIy+Bg3CO2o=", "narHash": "sha256-ptl5aRlCv9/uRSv2u8Hq8UFVFeZ6Q/bT049bpqNgc3w=",
"owner": "rafaelmardojai", "owner": "rafaelmardojai",
"repo": "firefox-gnome-theme", "repo": "firefox-gnome-theme",
"rev": "942159e73e40bf785816f7f1f5feed9ef3d7c8f9", "rev": "5602ed62d638142c1ab31dccd01dfbfb28841225",
"type": "github" "type": "github"
}, },
"original": { "original": {
@@ -392,27 +392,6 @@
} }
}, },
"flake-parts_2": { "flake-parts_2": {
"inputs": {
"nixpkgs-lib": [
"nvf",
"nixpkgs"
]
},
"locked": {
"lastModified": 1778716662,
"narHash": "sha256-m1Yf0wZ8j1OHjTc2UwHwyQRSnNeSgLJOd7q5Y45hzi4=",
"owner": "hercules-ci",
"repo": "flake-parts",
"rev": "f7c1a2d347e4c52d5fb8d10cb4d94b5884e546fb",
"type": "github"
},
"original": {
"owner": "hercules-ci",
"repo": "flake-parts",
"type": "github"
}
},
"flake-parts_3": {
"inputs": { "inputs": {
"nixpkgs-lib": [ "nixpkgs-lib": [
"stylix", "stylix",
@@ -420,11 +399,11 @@
] ]
}, },
"locked": { "locked": {
"lastModified": 1778716662, "lastModified": 1782949081,
"narHash": "sha256-m1Yf0wZ8j1OHjTc2UwHwyQRSnNeSgLJOd7q5Y45hzi4=", "narHash": "sha256-vp6Y/Grm98ESt6ceOkWiHWyZRDV3J1RID4w+6NWK9yA=",
"owner": "hercules-ci", "owner": "hercules-ci",
"repo": "flake-parts", "repo": "flake-parts",
"rev": "f7c1a2d347e4c52d5fb8d10cb4d94b5884e546fb", "rev": "17c9d6cdfc60c64f4ee8d306f9bc0b4ccb51481e",
"type": "github" "type": "github"
}, },
"original": { "original": {
@@ -564,18 +543,20 @@
"gnome-shell": { "gnome-shell": {
"flake": false, "flake": false,
"locked": { "locked": {
"lastModified": 1767737596, "host": "gitlab.gnome.org",
"narHash": "sha256-eFujfIUQDgWnSJBablOuG+32hCai192yRdrNHTv0a+s=", "lastModified": 1776175984,
"narHash": "sha256-RJFlFW8GiMei6oqUGrMkGEvVqOH8U7Q8abc1yK4VKD8=",
"owner": "GNOME", "owner": "GNOME",
"repo": "gnome-shell", "repo": "gnome-shell",
"rev": "ef02db02bf0ff342734d525b5767814770d85b49", "rev": "e0fdc4c13250e9a9b8ea9594c83925274f4a5dca",
"type": "github" "type": "gitlab"
}, },
"original": { "original": {
"host": "gitlab.gnome.org",
"owner": "GNOME", "owner": "GNOME",
"ref": "50.1",
"repo": "gnome-shell", "repo": "gnome-shell",
"rev": "ef02db02bf0ff342734d525b5767814770d85b49", "type": "gitlab"
"type": "github"
} }
}, },
"home-manager": { "home-manager": {
@@ -585,11 +566,11 @@
] ]
}, },
"locked": { "locked": {
"lastModified": 1781319724, "lastModified": 1789267039,
"narHash": "sha256-ZGuxexEMo4Xv28KJ0dX/m/PHN4oZIOnxHZpNTyrvx4M=", "narHash": "sha256-LWiBv9yAYFi2LPbUhDGHPGKYskJQjj2fw12OlyO1uQo=",
"owner": "nix-community", "owner": "nix-community",
"repo": "home-manager", "repo": "home-manager",
"rev": "8355f0a16b2dbb06a97959a918af5b239bbe05ae", "rev": "ec172013fa62135f58fb58dd17ae9651e8f39727",
"type": "github" "type": "github"
}, },
"original": { "original": {
@@ -606,11 +587,11 @@
] ]
}, },
"locked": { "locked": {
"lastModified": 1781365335, "lastModified": 1789676441,
"narHash": "sha256-zqDBhXMzfbdlO7F2bGHe7MOtB3xngd/+4ieMHDC+ZXo=", "narHash": "sha256-mOvO5VvycuBtOUe5EYI54vrLsWe+2KF/82fmwKooe48=",
"owner": "nix-community", "owner": "nix-community",
"repo": "home-manager", "repo": "home-manager",
"rev": "5b6f5733726a1b2ccafb5dec6ac4ca7299fad66c", "rev": "9d485f74cd27d17126ee34cb31005c39d20f741f",
"type": "github" "type": "github"
}, },
"original": { "original": {
@@ -730,28 +711,6 @@
"type": "github" "type": "github"
} }
}, },
"ndg": {
"inputs": {
"nixpkgs": [
"nvf",
"nixpkgs"
]
},
"locked": {
"lastModified": 1779233504,
"narHash": "sha256-YIKEyzh0NFQlD0O92LQQNMoVCDwV8yw1Xz0Iu+4ZC5U=",
"owner": "feel-co",
"repo": "ndg",
"rev": "86f6644411a64d5413711895b7cf6e0e1be465b6",
"type": "github"
},
"original": {
"owner": "feel-co",
"ref": "refs/tags/v2.8.0",
"repo": "ndg",
"type": "github"
}
},
"nix-darwin": { "nix-darwin": {
"inputs": { "inputs": {
"nixpkgs": [ "nixpkgs": [
@@ -759,11 +718,11 @@
] ]
}, },
"locked": { "locked": {
"lastModified": 1781242433, "lastModified": 1786845137,
"narHash": "sha256-bchLZZ3sRn740zyvD2icZSnNoTaanN0nw7l6fjVXO+E=", "narHash": "sha256-oQFip+v0luP8NIxJzmiW4Wu8bILsbFWom5l0zonl8hQ=",
"owner": "nix-darwin", "owner": "nix-darwin",
"repo": "nix-darwin", "repo": "nix-darwin",
"rev": "aabb2037edfc0f210723b72cd5f528aab5dd3f0b", "rev": "4cff07de74b50e64bdd68cd4e722ab5b6b35ee48",
"type": "github" "type": "github"
}, },
"original": { "original": {
@@ -794,11 +753,11 @@
"brew-src": "brew-src" "brew-src": "brew-src"
}, },
"locked": { "locked": {
"lastModified": 1781389246, "lastModified": 1788981439,
"narHash": "sha256-ORqLAo/hoJdsZC7UPAuEHev6S0+XIqKEC7vjo5prz1k=", "narHash": "sha256-fEaFq0XgpgWFPLfpq1UK4/8ylHd2T0+fo6O3hKz1LUM=",
"owner": "zhaofengli", "owner": "zhaofengli",
"repo": "nix-homebrew", "repo": "nix-homebrew",
"rev": "de7953a08ed4bb9245be043e468561c17b89130d", "rev": "09a921d0181146cf6163ec2cc1db7b6fd539a885",
"type": "github" "type": "github"
}, },
"original": { "original": {
@@ -847,11 +806,11 @@
] ]
}, },
"locked": { "locked": {
"lastModified": 1781182279, "lastModified": 1789164534,
"narHash": "sha256-V5EQQbDnmdiXGQXrEF1PEL7QYsFqfH8N1E89Z5ONwFk=", "narHash": "sha256-DoYGPM6QpnYBLWj9gGw6ZwAzIX+HrAVov1BoT+8Jixo=",
"owner": "nix-community", "owner": "nix-community",
"repo": "NixOS-WSL", "repo": "NixOS-WSL",
"rev": "5675822ba756e6e56f8f6a5a76e90e0da2ece94d", "rev": "72c92b11bb8289e6651c7fef29cc0a885fd6a255",
"type": "github" "type": "github"
}, },
"original": { "original": {
@@ -878,12 +837,11 @@
}, },
"nixpkgs-unstable": { "nixpkgs-unstable": {
"locked": { "locked": {
"lastModified": 1781074563, "lastModified": 1789546076,
"narHash": "sha256-md8WlXOlfnIeHeOScMTTHFyf2d6iaTwPl2apR5EQ3P4=", "narHash": "sha256-vWkSk5bbfTqdtMoSgD9FshACO8JCvXTFi+3cqEp0mH0=",
"owner": "NixOS", "rev": "b1b875982b17dabde9b4a37f3e229e74913e6db3",
"repo": "nixpkgs", "type": "tarball",
"rev": "9ae611a455b90cf061d8f332b977e387bda8e1ca", "url": "https://releases.nixos.org/nixos/unstable/nixos-26.11pre1074753.b1b875982b17/nixexprs.tar.zst"
"type": "github"
}, },
"original": { "original": {
"id": "nixpkgs", "id": "nixpkgs",
@@ -893,12 +851,11 @@
}, },
"nixpkgs_2": { "nixpkgs_2": {
"locked": { "locked": {
"lastModified": 1781216227, "lastModified": 1789542786,
"narHash": "sha256-9mUW6gNwoN2SWc/l0fW4svPNOulXLl8ijqKyeSOGgJE=", "narHash": "sha256-BGtBoaZNpOPDEBLTiWNFdYppnDjGhwrUq5/P15QwrrM=",
"owner": "NixOS", "rev": "4c7870105e7f1fdf9c48688c8d7efc21abf0688a",
"repo": "nixpkgs", "type": "tarball",
"rev": "a0374025a863d007d98e3297f6aa46cc3141c2f0", "url": "https://releases.nixos.org/nixos/26.05/nixos-26.05.9904.4c7870105e7f/nixexprs.tar.zst"
"type": "github"
}, },
"original": { "original": {
"id": "nixpkgs", "id": "nixpkgs",
@@ -965,11 +922,11 @@
] ]
}, },
"locked": { "locked": {
"lastModified": 1780281641, "lastModified": 1785549842,
"narHash": "sha256-M/+hUKoKbHXpV0xGVfELbN1Ds1aoe3pL5p5/t46YhVo=", "narHash": "sha256-DCwBZmGsySF7oKGTRgEv2HvpxVXkHT+38VhTM76k0B4=",
"owner": "nix-community", "owner": "nix-community",
"repo": "NUR", "repo": "NUR",
"rev": "30f9ae2f04174de63ba8bcf3580ca90843b28a01", "rev": "a9f987b57594e845e3e5cdd423b9a70846d70308",
"type": "github" "type": "github"
}, },
"original": { "original": {
@@ -981,20 +938,17 @@
"nvf": { "nvf": {
"inputs": { "inputs": {
"flake-compat": "flake-compat_3", "flake-compat": "flake-compat_3",
"flake-parts": "flake-parts_2",
"mnw": "mnw", "mnw": "mnw",
"ndg": "ndg",
"nixpkgs": [ "nixpkgs": [
"nixpkgs" "nixpkgs"
], ]
"systems": "systems"
}, },
"locked": { "locked": {
"lastModified": 1781374247, "lastModified": 1789510188,
"narHash": "sha256-34t1PpO8957G0KkE9YdZx5tsVW1HwMYxUsDep+q093o=", "narHash": "sha256-umec9LKkWjK89Yx4XpvQStkgfKvhK7GjVf5m21bjzKU=",
"owner": "notashelf", "owner": "notashelf",
"repo": "nvf", "repo": "nvf",
"rev": "b67d23fad44b27764ef4af290745188cf3bcbade", "rev": "cdc7e7aaa7eb521bba1b38f54c3228d52cc31703",
"type": "github" "type": "github"
}, },
"original": { "original": {
@@ -1110,6 +1064,29 @@
"type": "github" "type": "github"
} }
}, },
"plasma-manager": {
"inputs": {
"home-manager": [
"home-manager-unstable"
],
"nixpkgs": [
"nixpkgs-unstable"
]
},
"locked": {
"lastModified": 1785762349,
"narHash": "sha256-jZhZkzAwc7f3exzcTDJWP2WCAchCv0iNC3UF/QsahdQ=",
"owner": "nix-community",
"repo": "plasma-manager",
"rev": "a19a2a029fa180911bd89c554dca1616e10f4c1d",
"type": "github"
},
"original": {
"owner": "nix-community",
"repo": "plasma-manager",
"type": "github"
}
},
"pre-commit-hooks-nix": { "pre-commit-hooks-nix": {
"inputs": { "inputs": {
"flake-compat": [ "flake-compat": [
@@ -1151,6 +1128,7 @@
"nixpkgs": "nixpkgs_2", "nixpkgs": "nixpkgs_2",
"nixpkgs-unstable": "nixpkgs-unstable", "nixpkgs-unstable": "nixpkgs-unstable",
"nvf": "nvf", "nvf": "nvf",
"plasma-manager": "plasma-manager",
"slippi": "slippi", "slippi": "slippi",
"sops-nix": "sops-nix", "sops-nix": "sops-nix",
"srcds-nix": "srcds-nix", "srcds-nix": "srcds-nix",
@@ -1237,11 +1215,11 @@
] ]
}, },
"locked": { "locked": {
"lastModified": 1781025328, "lastModified": 1784166278,
"narHash": "sha256-Fi267TtVlhI+0EHlqpsXCGi2rQsWf6oc8MMwUpafEII=", "narHash": "sha256-TSvk8AK8ACGTSeC2v/tyWX3UiiaEQ5O4nX5jqVtEEEI=",
"owner": "lytedev", "owner": "lytedev",
"repo": "slippi-nix", "repo": "slippi-nix",
"rev": "eec3b4694c92d7c03d40dc52eff8e216fc92a3eb", "rev": "d87fef3580e6afc19bc3fffbba61069df2452cbf",
"type": "github" "type": "github"
}, },
"original": { "original": {
@@ -1257,11 +1235,11 @@
] ]
}, },
"locked": { "locked": {
"lastModified": 1780547341, "lastModified": 1789623319,
"narHash": "sha256-Gq8KNx5A7hBB3uGJaj6eQfLDIz5YdLu92gqBcvHvoUo=", "narHash": "sha256-kmlp8rPrvrXn58YiaANHKSWUijtUc7pwgerIywosOIM=",
"owner": "Mic92", "owner": "Mic92",
"repo": "sops-nix", "repo": "sops-nix",
"rev": "9ed65852b6257fbeae4355bc24ecfea307ca759a", "rev": "16954c1c360c3dc4d4b3b3e64df59f7e89452cb1",
"type": "github" "type": "github"
}, },
"original": { "original": {
@@ -1343,24 +1321,24 @@
"base16-helix": "base16-helix", "base16-helix": "base16-helix",
"base16-vim": "base16-vim", "base16-vim": "base16-vim",
"firefox-gnome-theme": "firefox-gnome-theme", "firefox-gnome-theme": "firefox-gnome-theme",
"flake-parts": "flake-parts_3", "flake-parts": "flake-parts_2",
"gnome-shell": "gnome-shell", "gnome-shell": "gnome-shell",
"nixpkgs": [ "nixpkgs": [
"nixpkgs-unstable" "nixpkgs-unstable"
], ],
"nur": "nur", "nur": "nur",
"systems": "systems_2", "systems": "systems",
"tinted-kitty": "tinted-kitty", "tinted-kitty": "tinted-kitty",
"tinted-schemes": "tinted-schemes", "tinted-schemes": "tinted-schemes",
"tinted-tmux": "tinted-tmux", "tinted-tmux": "tinted-tmux",
"tinted-zed": "tinted-zed" "tinted-zed": "tinted-zed"
}, },
"locked": { "locked": {
"lastModified": 1781018772, "lastModified": 1787771653,
"narHash": "sha256-C+cGIUaC6dqfwTbI+BwCd572PbESGA3WYxR1sLTqxkY=", "narHash": "sha256-DkkJSBOXWV/mja5Vy8az5g1KpZlsbUwlmH0BsQhowaQ=",
"owner": "nix-community", "owner": "nix-community",
"repo": "stylix", "repo": "stylix",
"rev": "a378e4c09031fb15a4d65da88aa628f71fc52f6b", "rev": "5e3809851f486e7fc7e84b40f174c74b60ecc784",
"type": "github" "type": "github"
}, },
"original": { "original": {
@@ -1371,30 +1349,16 @@
}, },
"systems": { "systems": {
"locked": { "locked": {
"lastModified": 1681028828, "lastModified": 1774449309,
"narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=", "narHash": "sha256-brhZ8DmuGtzkCYHJg4HEd602amKm89Y9ytsFZ5uWD1w=",
"owner": "nix-systems", "owner": "nix-systems",
"repo": "default", "repo": "default",
"rev": "da67096a3b9bf56a91d16901293e51ba5b49a27e", "rev": "c29398b59d2048c4ab79345812849c9bd15e9150",
"type": "github"
},
"original": {
"owner": "nix-systems",
"repo": "default",
"type": "github"
}
},
"systems_2": {
"locked": {
"lastModified": 1681028828,
"narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=",
"owner": "nix-systems",
"repo": "default",
"rev": "da67096a3b9bf56a91d16901293e51ba5b49a27e",
"type": "github" "type": "github"
}, },
"original": { "original": {
"owner": "nix-systems", "owner": "nix-systems",
"ref": "future-26.11",
"repo": "default", "repo": "default",
"type": "github" "type": "github"
} }
@@ -1418,11 +1382,11 @@
"tinted-schemes": { "tinted-schemes": {
"flake": false, "flake": false,
"locked": { "locked": {
"lastModified": 1777806186, "lastModified": 1785153830,
"narHash": "sha256-PDF0/wObw4nIsSBeXVYLsloXOiphXCgIdsrNcVXguKs=", "narHash": "sha256-fNdfCTeCXU3tZG3TMincd+u68qBHQgCr2Ljr/M1mWP0=",
"owner": "tinted-theming", "owner": "tinted-theming",
"repo": "schemes", "repo": "schemes",
"rev": "0c94645546f4f3ddac77a1a5fce54eb95bf50795", "rev": "9bd28ed313560db3c5b605c63bc4e309e78e3fc8",
"type": "github" "type": "github"
}, },
"original": { "original": {
@@ -1434,11 +1398,11 @@
"tinted-tmux": { "tinted-tmux": {
"flake": false, "flake": false,
"locked": { "locked": {
"lastModified": 1778379944, "lastModified": 1785031658,
"narHash": "sha256-wPDFzMGSlARlw0Sfsn48Q2+jPSfk6N0Ng6BC/d+7Q24=", "narHash": "sha256-mZp9O2LjzdMzlqQF3l3fjqsuPBzXy+1qTfBEUGjTlpk=",
"owner": "tinted-theming", "owner": "tinted-theming",
"repo": "tinted-tmux", "repo": "tinted-tmux",
"rev": "fe0203a198690e71a5ff11e08812a4673de3678d", "rev": "5d2c67f61ea7af36f16865ab6d541cdba41dc257",
"type": "github" "type": "github"
}, },
"original": { "original": {
@@ -1450,11 +1414,11 @@
"tinted-zed": { "tinted-zed": {
"flake": false, "flake": false,
"locked": { "locked": {
"lastModified": 1778378178, "lastModified": 1785030526,
"narHash": "sha256-OXPXRIQgGwV77HjYRryOHguh4ALX96jkg+tseLkGgHA=", "narHash": "sha256-klZf8UviewRkxuu74Bhbq6tqy7oxebQC7UVRWbbtQxU=",
"owner": "tinted-theming", "owner": "tinted-theming",
"repo": "base16-zed", "repo": "base16-zed",
"rev": "9cd816033ff969415b190722cddf134e78a5665f", "rev": "16f5a8adf4a6b1310d0a61ab172de963e8f76a02",
"type": "github" "type": "github"
}, },
"original": { "original": {
@@ -1486,11 +1450,11 @@
}, },
"vpn-confinement": { "vpn-confinement": {
"locked": { "locked": {
"lastModified": 1778182451, "lastModified": 1789394839,
"narHash": "sha256-Bz3n2THDGf90Z9gMqhH/J492prYH8B6RFRlxv/fPBwc=", "narHash": "sha256-trdjVJKmDBbzgbP8pd+R7iKbGkdRu0nmXgQlBR/hEiU=",
"owner": "Maroka-chan", "owner": "Maroka-chan",
"repo": "VPN-Confinement", "repo": "VPN-Confinement",
"rev": "cf5bfc4c3559f2e783698b1aa23c165072039a7d", "rev": "a21f66ccd9f644c3770ccdf287cb380c00192628",
"type": "github" "type": "github"
}, },
"original": { "original": {
+6
View File
@@ -19,6 +19,11 @@
url = "github:nix-community/home-manager"; url = "github:nix-community/home-manager";
inputs.nixpkgs.follows = "nixpkgs-unstable"; inputs.nixpkgs.follows = "nixpkgs-unstable";
}; };
plasma-manager = {
url = "github:nix-community/plasma-manager";
inputs.nixpkgs.follows = "nixpkgs-unstable";
inputs.home-manager.follows = "home-manager-unstable";
};
nix-homebrew.url = "github:zhaofengli/nix-homebrew"; nix-homebrew.url = "github:zhaofengli/nix-homebrew";
nix-flatpak.url = "github:gmodena/nix-flatpak/?ref=latest"; nix-flatpak.url = "github:gmodena/nix-flatpak/?ref=latest";
sops-nix = { sops-nix = {
@@ -70,6 +75,7 @@
nix-darwin, nix-darwin,
nix-homebrew, nix-homebrew,
nixos-wsl, nixos-wsl,
plasma-manager,
... ...
} @ inputs: let } @ inputs: let
systems = { systems = {
+8 -5
View File
@@ -15,6 +15,7 @@
darwin = { darwin = {
syncthing.enable = true; syncthing.enable = true;
tailscale.enable = true; tailscale.enable = true;
nextdns.enable = true;
yubikey.enable = true; yubikey.enable = true;
work.enable = true; work.enable = true;
apps.enable = true; apps.enable = true;
@@ -56,7 +57,7 @@
formulae = []; formulae = [];
casks = []; casks = [];
commands = []; commands = [];
#taps = ["mhaeuser/mhaeuser"]; taps = ["rogeriopradoj/cask-peazip"];
}; };
}; };
@@ -66,12 +67,12 @@
onActivation = { onActivation = {
cleanup = "zap"; cleanup = "zap";
autoUpdate = false; autoUpdate = false;
upgrade = false; upgrade = true;
}; };
# taps = [ taps = [
# "mhaeuser/mhaeuser" "rogeriopradoj/cask-peazip"
# ]; ];
brews = [ brews = [
"mas" "mas"
@@ -83,6 +84,8 @@
"kitty" "kitty"
"linearmouse" "linearmouse"
"betterdisplay" "betterdisplay"
"rectangle"
"peazip"
]; ];
masApps = { masApps = {
# "name" = app_id_number; # "name" = app_id_number;
+1 -1
View File
@@ -24,6 +24,7 @@
# base system package install list # base system package install list
environment.systemPackages = with pkgs; [ environment.systemPackages = with pkgs; [
wget wget
sl
curl curl
rsync rsync
git git
@@ -34,7 +35,6 @@
python3 python3
lf lf
btop btop
rectangle
pinentry_mac pinentry_mac
]; ];
+13 -1
View File
@@ -53,7 +53,15 @@
powerManagement.powertop.enable = true; powerManagement.powertop.enable = true;
# things are better this way # things are better this way
users.defaultUserShell = pkgs.zsh; users = {
defaultUserShell = pkgs.zsh;
users.root = {
openssh.authorizedKeys.keys = [
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIO06en1r4+zg8JMGPq7WiZeh/DBUvfhDJX3e+J5Z5Ttk blake@snowbelle"
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIP0FLKK9yEPYpGuCjoX0e7Ky/zTPfzDk7IkrR3tOmELP blake@vaniville"
];
};
};
# base system package install list # base system package install list
environment.systemPackages = with pkgs; [ environment.systemPackages = with pkgs; [
@@ -117,6 +125,10 @@
command = "/run/current-system/sw/bin/rsync"; command = "/run/current-system/sw/bin/rsync";
options = ["NOPASSWD"]; options = ["NOPASSWD"];
} }
{
command = "/etc/profiles/per-user/blake/bin/lf";
options = ["NOPASSWD"];
}
]; ];
} }
]; ];
+30 -47
View File
@@ -20,6 +20,7 @@
#../../../modules/gameservers/srcds #../../../modules/gameservers/srcds
../../../modules/gameservers/minecraft_recpro ../../../modules/gameservers/minecraft_recpro
../../../modules/gameservers/minecraft_modded ../../../modules/gameservers/minecraft_modded
../../../modules/gameservers/valheim
]; ];
home-manager.users.blake.imports = [ home-manager.users.blake.imports = [
@@ -37,7 +38,7 @@
}; };
keepalive = { keepalive = {
enable = true; enable = true;
url = "https://up.blakedheld.xyz/api/push/7DAcvsedwB?status=up&msg=fuckingvibing&ping="; url = "https://up.holocron.blue/api/push/7DAcvsedwB?status=up&msg=fuckingvibing&ping=";
}; };
}; };
@@ -45,24 +46,28 @@
enable = true; enable = true;
base_domain = "lumiose.holocron.blue"; base_domain = "lumiose.holocron.blue";
host_ip = "10.10.0.11"; host_ip = "10.10.0.11";
gitea.enable = true; gitea.enable = false;
glance.enable = true; glance.enable = true;
immich = { immich = {
enable = true; enable = true;
data_dir = "/holocron/srv/immich"; data_dir = "/holocron/srv/immich";
backup = false; backup = false;
}; };
vaultwarden.enable = true; vaultwarden.enable = false;
#searx.enable = true; #searx.enable = true;
# home assistant # home assistant
home.enable = true; home.enable = true;
homebox.enable = true;
# network # network
tailscale.enable = true; tailscale.enable = true;
caddy.enable = true; caddy = {
enable = true;
keys = false;
};
dnsmasq.enable = true; dnsmasq.enable = true;
# mediastack # mediastack
mediastack.enable = true; mediastack.enable = true;
qbittorrent.vpn_inf = "enp37s0f1.69"; qbittorrent.vpn_inf = "enp34s0.69";
# system # system
backups.enable = true; backups.enable = true;
motd.enable = true; motd.enable = true;
@@ -87,6 +92,7 @@
gameservers = { gameservers = {
minecraft_recpro.enable = true; minecraft_recpro.enable = true;
minecraft_modded.enable = false; minecraft_modded.enable = false;
valheim.enable = true;
}; };
# boot (systemd is going on me) # boot (systemd is going on me)
@@ -107,54 +113,31 @@
networking = { networking = {
hostName = "lumiose"; # hostname hostName = "lumiose"; # hostname
hostId = "007f0200"; hostId = "007f0200";
# dhcpcd.enable = false; getaddrinfo = {
# interfaces = { enable = true;
# enp34s0 = { precedence = {
# useDHCP = true; "::ffff:0:0/96" = 100;
# }; };
# vlan10 = { };
# useDHCP = true;
# };
# vlan69 = {
# useDHCP = true;
# };
# };
# vlans = {
# vlan10 = {
# id = 10;
# interface = "enp37s0f0";
# };
# vlan69 = {
# id = 69;
# interface = "enp37s0f0";
# };
# };
# defaultGateway = "10.10.0.1";
# nameservers = ["10.10.0.1"];
networkmanager = { networkmanager = {
enable = true; # the goat enable = true; # the goat
dns = "systemd-resolved"; # the backup dancer! dns = "systemd-resolved"; # the backup dancer!
ensureProfiles.profiles = { ensureProfiles.profiles = {
vpn = { vpn = {
ipv4 = {
method = "manual";
addresses = "10.69.0.11/24";
gateway = "10.69.0.1";
};
ethernet.mac-address = "02:ea:6c:3c:9f:cd"; ethernet.mac-address = "02:ea:6c:3c:9f:cd";
connection.type = "vlan"; connection.type = "vlan";
connection.id = "vpn"; connection.id = "vpn";
connection.interface-name = "enp37s0f1.69"; # or just "vpn-vlan" connection.interface-name = "enp34s0.69"; # or just "vpn-vlan"
vlan.interface-name = "enp37s0f1.69"; # or just "vpn-vlan" vlan.interface-name = "enp34s0.69"; # or just "vpn-vlan"
vlan.parent = "enp37s0f1"; vlan.parent = "enp34s0";
vlan.id = 69; vlan.id = 69;
#ipv4.dns = "9.9.9.9"; #ipv4.dns = "9.9.9.9";
}; };
# lan = {
# ethernet.mac-address = "02:11:61:c5:31:b6";
# connection.type = "vlan";
# connection.id = "lan";
# connection.interface-name = "enp37s0f1.20"; # or just "vpn-vlan"
# vlan.interface-name = "enp37s0f1.20"; # or just "vpn-vlan"
# vlan.parent = "enp37s0f1";
# vlan.id = 20;
# #ipv4.dns = "9.9.9.9";
# };
}; };
}; };
}; };
@@ -165,12 +148,11 @@
networking.firewall.allowedTCPPorts = [ networking.firewall.allowedTCPPorts = [
80 # set - http 80 # set - http
111 # set - portmapper for nfs 111 # set - portmapper for nfs
139 # set - smb
443 # set - https 443 # set - https
137 137 # set - smb
138 138 # set - smb
139 139 # set - smb
445 # set - cifs 445 # set - smb
1198 1198
1883 # set - mqtt 1883 # set - mqtt
2049 # set - nfs 2049 # set - nfs
@@ -186,6 +168,7 @@
boot.initrd.availableKernelModules = ["nvme" "xhci_pci" "ahci" "usb_storage" "usbhid" "sd_mod"]; boot.initrd.availableKernelModules = ["nvme" "xhci_pci" "ahci" "usb_storage" "usbhid" "sd_mod"];
boot.initrd.kernelModules = []; boot.initrd.kernelModules = [];
boot.kernelModules = ["kvm-amd"]; boot.kernelModules = ["kvm-amd"];
boot.kernelParams = ["ipv6.disable=1"];
boot.extraModulePackages = []; boot.extraModulePackages = [];
nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux"; nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux";
hardware.cpu.amd.updateMicrocode = lib.mkDefault config.hardware.enableRedistributableFirmware; hardware.cpu.amd.updateMicrocode = lib.mkDefault config.hardware.enableRedistributableFirmware;
+9 -6
View File
@@ -15,7 +15,7 @@
../../../modules/homelab ../../../modules/homelab
#../../../modules/fileshares/holocron #../../../modules/fileshares/holocron
#../../../modules/gameservers/minecraft_recpro #../../../modules/gameservers/minecraft_recpro
#../../../modules/gameservers/minecraft_modded ../../../modules/gameservers/minecraft_modded
]; ];
home-manager.users.blake.imports = [ home-manager.users.blake.imports = [
@@ -33,7 +33,7 @@
}; };
keepalive = { keepalive = {
enable = true; enable = true;
url = "https://up.blakedheld.xyz/api/push/kMoYviAuCL?status=up&msg=bigchilling&ping="; url = "https://up.holocron.blue/api/push/kMoYviAuCL?status=up&msg=bigchilling&ping=";
}; };
}; };
# holocron = { # holocron = {
@@ -61,7 +61,7 @@
# mediastack # mediastack
mediastack.enable = false; mediastack.enable = false;
# system # system
backups.enable = true; backups.enable = false;
motd.enable = false; motd.enable = false;
uptime-kuma.enable = false; uptime-kuma.enable = false;
# ai # ai
@@ -70,10 +70,13 @@
wyoming.enable = false; wyoming.enable = false;
}; };
# gameservers = { gameservers = {
# minecraft_recpro.enable = true; # minecraft_recpro.enable = true;
# minecraft_modded.enable = true; minecraft_modded = {
# }; enable = true;
url = "raceraskedforthisenjoyyall.recoil.pro";
};
};
# boot (systemd is going on me) # boot (systemd is going on me)
boot.loader.systemd-boot.enable = true; # systemd your pretty cool ya know boot.loader.systemd-boot.enable = true; # systemd your pretty cool ya know
+34 -15
View File
@@ -30,8 +30,9 @@ in {
tailscale.enable = false; tailscale.enable = false;
}; };
homelab = { homelab = {
base_domain = "vaniville.lan"; enable = true;
host_ip = "10.10.0.11"; base_domain = "vaniville.holocron.blue";
host_ip = "100.100.1.10";
ddns.enable = true; ddns.enable = true;
uptime-kuma = { uptime-kuma = {
enable = true; enable = true;
@@ -39,8 +40,17 @@ in {
}; };
caddy = { caddy = {
enable = true; enable = true;
keys = false; keys = true;
}; };
backups = {
enable = true;
databases = false;
homelab = true;
backup_repo = "/var/lib/backups/homelab";
offsite_dir = "lifeboat/vaniville/homelab";
};
gitea.enable = true;
vaultwarden.enable = true;
home.enable = false; home.enable = false;
}; };
@@ -112,9 +122,9 @@ in {
# what actually does the forwarding # what actually does the forwarding
firewall = { firewall = {
enable = true; enable = true;
allowedTCPPorts = [22 80 443 25777 7567 21115 21116 21117 21118 21119]; allowedTCPPorts = [22 80 443 25777 25579 7567 21115 21116 21117 21118 21119];
# tailscale will also need its UDP port open: # tailscale will also need its UDP port open:
allowedUDPPorts = [config.services.tailscale.port 25777 21116]; allowedUDPPorts = [config.services.tailscale.port 2456 2457 25777 21116 25580];
trustedInterfaces = ["tailscale0"]; trustedInterfaces = ["tailscale0"];
/* /*
iptables -t nat -A PREROUTING -i eth0 -p tcp --dport 80 -j DNAT --to-destination ${snowbelle_ip}:80 # http iptables -t nat -A PREROUTING -i eth0 -p tcp --dport 80 -j DNAT --to-destination ${snowbelle_ip}:80 # http
@@ -123,21 +133,29 @@ in {
iptables -t nat -A POSTROUTING -o tailscale0 -p tcp --dport 80 -d ${snowbelle_ip}/32 -j SNAT --to-source ${vpsip4} # http iptables -t nat -A POSTROUTING -o tailscale0 -p tcp --dport 80 -d ${snowbelle_ip}/32 -j SNAT --to-source ${vpsip4} # http
iptables -t nat -A POSTROUTING -o tailscale0 -p tcp --dport 443 -d ${snowbelle_ip}/32 -j SNAT --to-source ${vpsip4} # https iptables -t nat -A POSTROUTING -o tailscale0 -p tcp --dport 443 -d ${snowbelle_ip}/32 -j SNAT --to-source ${vpsip4} # https
*/ */
# iptables -t nat -A PREROUTING -i eth0 -p tcp --dport 7567 -j DNAT --to-destination ${lumiose_ip}:7567 # gitea ssh
# iptables -t nat -A POSTROUTING -o tailscale0 -p tcp --dport 7567 -d ${lumiose_ip}/32 -j SNAT --to-source ${vpsip4} # gitea ssh
extraCommands = '' extraCommands = ''
# Clear any previous rules if you are iterating # Clear any previous rules if you are iterating
iptables -t nat -F iptables -t nat -F
# DNAT: internet -> homelab over tailscale # DNAT: internet -> homelab over tailscale
iptables -t nat -A PREROUTING -i eth0 -p tcp --dport 7567 -j DNAT --to-destination ${lumiose_ip}:7567 # gitea ssh
iptables -t nat -A PREROUTING -i eth0 -p tcp --dport 25777 -j DNAT --to-destination ${lumiose_ip}:25777 # recpro mc iptables -t nat -A PREROUTING -i eth0 -p tcp --dport 25777 -j DNAT --to-destination ${lumiose_ip}:25777 # recpro mc
iptables -t nat -A PREROUTING -i eth0 -p udp --dport 25777 -j DNAT --to-destination ${lumiose_ip}:25777 # recpro mc iptables -t nat -A PREROUTING -i eth0 -p udp --dport 25777 -j DNAT --to-destination ${lumiose_ip}:25777 # recpro mc
iptables -t nat -A PREROUTING -i eth0 -p tcp --dport 25778 -j DNAT --to-destination ${lumiose_ip}:25778 # cbblemon mc iptables -t nat -A PREROUTING -i eth0 -p tcp --dport 25579 -j DNAT --to-destination ${snowbelle_ip}:25579 # craftoria mc
iptables -t nat -A PREROUTING -i eth0 -p udp --dport 25580 -j DNAT --to-destination ${snowbelle_ip}:25580 # craftoria mc voice chat
iptables -t nat -A PREROUTING -i eth0 -p udp --dport 2456 -j DNAT --to-destination ${lumiose_ip}:2456 # valheim server
iptables -t nat -A PREROUTING -i eth0 -p udp --dport 2457 -j DNAT --to-destination ${lumiose_ip}:2457 # valheim server
# SNAT: ensure replies go back through VPS tailscale IP # SNAT: ensure replies go back through VPS tailscale IP
iptables -t nat -A POSTROUTING -o tailscale0 -p tcp --dport 7567 -d ${lumiose_ip}/32 -j SNAT --to-source ${vpsip4} # gitea ssh
iptables -t nat -A POSTROUTING -o tailscale0 -p tcp --dport 25777 -d ${lumiose_ip}/32 -j SNAT --to-source ${vpsip4} # recpro mc iptables -t nat -A POSTROUTING -o tailscale0 -p tcp --dport 25777 -d ${lumiose_ip}/32 -j SNAT --to-source ${vpsip4} # recpro mc
iptables -t nat -A POSTROUTING -o tailscale0 -p udp --dport 25777 -d ${lumiose_ip}/32 -j SNAT --to-source ${vpsip4} # recpro mc iptables -t nat -A POSTROUTING -o tailscale0 -p udp --dport 25777 -d ${lumiose_ip}/32 -j SNAT --to-source ${vpsip4} # recpro mc
iptables -t nat -A POSTROUTING -o tailscale0 -p tcp --dport 25778 -d ${lumiose_ip}/32 -j SNAT --to-source ${vpsip4} # cbblemon mc iptables -t nat -A POSTROUTING -o tailscale0 -p tcp --dport 25579 -d ${snowbelle_ip}/32 -j SNAT --to-source ${vpsip4} # craftoria mc
iptables -t nat -A POSTROUTING -o tailscale0 -p udp --dport 25580 -d ${snowbelle_ip}/32 -j SNAT --to-source ${vpsip4} # craftoria mc voicechat
iptables -t nat -A POSTROUTING -o tailscale0 -p udp --dport 2456 -d ${lumiose_ip}/32 -j SNAT --to-source ${vpsip4} # valheim server
iptables -t nat -A POSTROUTING -o tailscale0 -p udp --dport 2457 -d ${lumiose_ip}/32 -j SNAT --to-source ${vpsip4} # valheim server
''; '';
}; };
}; };
@@ -167,15 +185,9 @@ in {
"media.${homelab.public_domain}".extraConfig = '' "media.${homelab.public_domain}".extraConfig = ''
reverse_proxy ${lumiose_ip}:7100 reverse_proxy ${lumiose_ip}:7100
''; '';
"pass.${homelab.public_domain}".extraConfig = ''
reverse_proxy ${lumiose_ip}:7701
'';
"photos.${homelab.public_domain}".extraConfig = '' "photos.${homelab.public_domain}".extraConfig = ''
reverse_proxy ${lumiose_ip}:7702 reverse_proxy ${lumiose_ip}:7702
''; '';
"git.${homelab.public_domain}".extraConfig = ''
reverse_proxy ${lumiose_ip}:7703
'';
"hass.${homelab.public_domain}".extraConfig = '' "hass.${homelab.public_domain}".extraConfig = ''
reverse_proxy ${lumiose_ip}:7704 { reverse_proxy ${lumiose_ip}:7704 {
header_up Host {host} header_up Host {host}
@@ -184,6 +196,13 @@ in {
header_up X-Forwarded-Proto https header_up X-Forwarded-Proto https
} }
''; '';
# now hosted on vaniville!
# "pass.${homelab.public_domain}".extraConfig = ''
# reverse_proxy 127.0.0.1:7701
# '';
# "git.${homelab.public_domain}".extraConfig = ''
# reverse_proxy localhost:7703
# '';
}; };
}; };
+2 -2
View File
@@ -26,7 +26,7 @@
ssh.enable = true; ssh.enable = true;
sops.enable = true; sops.enable = true;
yubikey.enable = true; yubikey.enable = true;
yubikey.lock_on_remove = true; yubikey.lock_on_remove = false;
tailscale.enable = true; tailscale.enable = true;
syncthing.enable = true; syncthing.enable = true;
flatpak.enable = true; flatpak.enable = true;
@@ -37,7 +37,7 @@
}; };
desktop = { desktop = {
pipewire.enable = true; pipewire.enable = true;
hypr.enable = true; hypr.enable = false;
greetd.enable = true; greetd.enable = true;
kde.enable = true; kde.enable = true;
}; };
+8 -2
View File
@@ -23,6 +23,9 @@ in {
"sl" "sl"
"cowsay" "cowsay"
"apfel" "apfel"
"yt-dlp"
"ffmpeg"
"ffmpeg-full"
]; ];
casks = [ casks = [
"gnucash" "gnucash"
@@ -33,7 +36,7 @@ in {
"grandperspective" "grandperspective"
"spotify" "spotify"
"obs" "obs"
# "gimp" "gimp"
"audacity" "audacity"
"anki" "anki"
"rustdesk" "rustdesk"
@@ -41,6 +44,9 @@ in {
"transmission" "transmission"
"finetune" "finetune"
"yacreader" "yacreader"
"keepassxc"
"thunderbird"
"musicbrainz-picard"
]; ];
masApps = { masApps = {
"pages" = 361309726; "pages" = 361309726;
@@ -50,7 +56,7 @@ in {
"darkreader" = 1438243180; "darkreader" = 1438243180;
"ghostery" = 6504861501; "ghostery" = 6504861501;
"privacy" = 6449850851; "privacy" = 6449850851;
#"unifi" = 1057750338; "flo" = 6529533140;
}; };
}; };
}; };
+1 -1
View File
@@ -6,6 +6,7 @@
}: { }: {
imports = [ imports = [
./tailscale ./tailscale
./nextdns
./syncthing ./syncthing
./yubikey ./yubikey
./work ./work
@@ -13,5 +14,4 @@
./cyber ./cyber
./gaming ./gaming
]; ];
} }
+3 -5
View File
@@ -3,8 +3,7 @@
config, config,
lib, lib,
... ...
}: }: let
let
service = "gaming"; service = "gaming";
cfg = config.darwin.${service}; cfg = config.darwin.${service};
in { in {
@@ -13,7 +12,6 @@ in {
}; };
config = lib.mkIf cfg.enable { config = lib.mkIf cfg.enable {
# environment.systemPackages = with pkgs; [ # environment.systemPackages = with pkgs; [
# uhhh # uhhh
# ]; # ];
@@ -25,8 +23,8 @@ in {
"steam" "steam"
"prismlauncher" "prismlauncher"
"discord" "discord"
"runelite" # "runelite"
"jagex" # "jagex"
]; ];
masApps = { masApps = {
}; };
+23
View File
@@ -0,0 +1,23 @@
{
pkgs,
config,
lib,
inputs,
...
}: let
service = "nextdns";
cfg = config.darwin.${service};
in {
options.darwin.${service} = {
enable = lib.mkEnableOption "enables ${service}";
};
config = lib.mkIf cfg.enable {
services.${service} = {
enable = true;
arguments = [
"-profile 527db2"
];
};
};
}
+13 -11
View File
@@ -8,23 +8,25 @@
service = "tailscale"; service = "tailscale";
cfg = config.darwin.${service}; cfg = config.darwin.${service};
in { in {
options.darwin.tailscale = { options.darwin.tailscale = {
enable = lib.mkEnableOption "enables tailscale"; enable = lib.mkEnableOption "enables tailscale";
}; };
config = lib.mkIf cfg.enable { config = lib.mkIf cfg.enable {
services.tailscale = { # services.tailscale = {
enable = true; # enable = true;
#overrideLocalDns = true; # #overrideLocalDns = true;
#authKeyFile = authkey_file; # #authKeyFile = authkey_file;
}; # };
homebrew = { # environment.systemPackages = with pkgs; [
casks = [ # tailscale-gui
"tailscale-app" # ];
];
};
# homebrew = {
# casks = [
# "tailscale-app"
# ];
# };
}; };
} }
+6 -7
View File
@@ -8,17 +8,16 @@
service = "work"; service = "work";
cfg = config.darwin.${service}; cfg = config.darwin.${service};
in { in {
options.darwin.work = { options.darwin.work = {
enable = lib.mkEnableOption "installs apps for work"; enable = lib.mkEnableOption "installs apps for work";
}; };
config = lib.mkIf cfg.enable { config = lib.mkIf cfg.enable {
services.tailscale = { # services.tailscale = {
enable = true; # enable = true;
#overrideLocalDns = true; # #overrideLocalDns = true;
#authKeyFile = authkey_file; # #authKeyFile = authkey_file;
}; # };
homebrew = { homebrew = {
casks = [ casks = [
@@ -27,11 +26,11 @@ in {
"microsoft-office" "microsoft-office"
"jump-desktop" "jump-desktop"
"wifiman" "wifiman"
"adobe-acrobat-pro"
]; ];
masApps = { masApps = {
"configurator" = 1037126344; "configurator" = 1037126344;
}; };
}; };
}; };
} }
+37 -1
View File
@@ -12,6 +12,42 @@ in {
config = lib.mkIf cfg.enable { config = lib.mkIf cfg.enable {
# enable kde plasma # enable kde plasma
services.desktopManager.plasma6.enable = true; services = {
desktopManager.plasma6.enable = true;
#displayManager.sddm.enable = true;
#displayManager.sddm.wayland.enable = true;
};
environment.systemPackages = with pkgs; [
# KDE Utilities
kdePackages.discover # Optional: Software center for Flatpaks/firmware updates
kdePackages.kcalc # Calculator
kdePackages.kcharselect # Character map
kdePackages.kclock # Clock app
kdePackages.kcolorchooser # Color picker
kdePackages.kolourpaint # Simple paint program
kdePackages.ksystemlog # System log viewer
kdePackages.sddm-kcm # SDDM configuration module
kdiff3 # File/directory comparison tool
# Hardware/System Utilities (Optional)
kdePackages.isoimagewriter # Write hybrid ISOs to USB
kdePackages.partitionmanager # Disk and partition management
hardinfo2 # System benchmarks and hardware info
wayland-utils # Wayland diagnostic tools
wl-clipboard # Wayland copy/paste support
vlc # Media player
];
environment.plasma6.excludePackages = with pkgs; [
kdePackages.elisa # Music player
kdePackages.kdepim-runtime # Akonadi agents
kdePackages.kmahjongg
#kdePackages.kmines
kdePackages.konversation # IRC client
kdePackages.kpat # Solitaire
kdePackages.ksudoku
kdePackages.ktorrent
];
}; };
} }
@@ -1,20 +0,0 @@
{
pkgs,
config,
lib,
inputs,
...
}: {
# services show up in glance in reverse import order lmao
imports = [
./nfs
./smb
./zfs
#./syncthing
#./copyparty
./perms
];
# define the groups used for backups and archives
users.groups.archives = {gid = 727;};
}
@@ -1,28 +0,0 @@
{
pkgs,
config,
lib,
...
}:
# define nfs exports
let
cfg = config.holocron.nfs;
nfs_exports = ''
/holocron/media *(ro,sync,no_subtree_check)
'';
#/holocron/users *(rw,sync,no_subtree_check,no_root_squash)
in {
options.holocron.nfs = {
enable = lib.mkEnableOption "enables nfs";
};
config = lib.mkIf cfg.enable {
# enable nfs with all exports
services.nfs = {
server = {
enable = true;
exports = nfs_exports;
};
};
};
}
@@ -1,65 +0,0 @@
{
config,
pkgs,
lib,
...
}: let
service = "ensure_perms";
cfg = config.holocron.${service};
# define variables for paths
archives_path = "/holocron/archives";
media_path = "/holocron/media";
users_path = "/holocron/users";
in {
options.holocron.ensure_perms = {
enable = lib.mkEnableOption "enables perms ensurence script";
};
config = lib.mkIf cfg.enable {
# service to run periodically to reset the perms on all zpools
# everything works fine without this, just for peace of mind
# and to clean up the ownership from the arr stack in /holocron/media
systemd.services.${service} = {
description = "ensure file permissions for archives, media and user folders";
serviceConfig = {
Type = "oneshot";
ExecStart = pkgs.writeShellScript "ensure_perms" ''
# Fix ownership for archives directory
echo "starting ${archives_path}"
chown -Rc root:archives ${archives_path}
find "${archives_path}" -type d -exec chmod 2770 "$@" {} +
find "${archives_path}" -type f -exec chmod 660 "$@" {} +
# Fix ownership for media directory
echo "starting ${media_path}"
chown -Rc root:media ${media_path}
find "${media_path}" -type d -exec chmod 2770 "$@" {} +
find "${media_path}" -type f -exec chmod 660 "$@" {} +
# Fix user directories
for user_dir in ${users_path}/*; do
if [ -d "$user_dir" ]; then
user=$(basename "$user_dir")
echo "starting $user_dir"
chown -Rc $user:$user $user_dir
find $user_dir -type d -exec chmod 2770 "$@" {} +
find $user_dir -type f -exec chmod 660 "$@" {} +
fi
done
echo "fin"
'';
};
};
systemd.timers.${service} = {
description = "run script to ensure_perms daily";
wantedBy = ["timers.target"];
timerConfig = {
OnCalendar = "03:30";
Persistent = true;
};
};
};
}
@@ -1,97 +0,0 @@
{
pkgs,
config,
lib,
...
}:
# define smb shares
let
cfg = config.holocron.smb;
smb_shares = {
global = {
"ea support" = "yes";
"vfs objects" = "catia fruit streams_xattr";
"fruit:aapl" = "yes";
"fruit:metadata" = "stream";
"fruit:model" = "MacSamba";
"fruit:posix_rename" = "yes";
"fruit:nfs_aces" = "no";
"fruit:veto_appledouble" = "no";
"fruit:wipe_intentionally_left_blank_rfork" = "yes";
"fruit:delete_empty_adfiles" = "yes";
};
archives = {
path = "/holocron/archives";
browseable = true;
writable = true;
guestOk = false;
"create mask" = "0775";
"directory mask" = "0775";
};
timemachine = {
browseable = true;
"path" = "/holocron/archives/timemachine";
"valid users" = "blake";
"public" = "no";
"writeable" = "yes";
"force user" = "blake";
"fruit:aapl" = "yes";
"fruit:time machine" = "yes";
"vfs objects" = "catia fruit streams_xattr";
};
users = {
path = "/holocron/users";
browseable = true;
writable = true;
guestOk = false;
"create mask" = "0660";
"directory mask" = "0770";
};
media = {
path = "/holocron/media";
browseable = true;
writable = true;
guestOk = false;
"create mask" = "0775";
"directory mask" = "0775";
};
};
in {
options.holocron.smb = {
enable = lib.mkEnableOption "enables smb";
};
config = lib.mkIf cfg.enable {
# enable smb with all shares
services.samba = {
enable = true;
settings = smb_shares;
};
# Ensure Time Machine can discover the share without `tmutil`
services.avahi = {
extraServiceFiles = {
timemachine = ''
<?xml version="1.0" standalone='no'?>
<!DOCTYPE service-group SYSTEM "avahi-service.dtd">
<service-group>
<name replace-wildcards="yes">%h</name>
<service>
<type>_smb._tcp</type>
<port>445</port>
</service>
<service>
<type>_device-info._tcp</type>
<port>0</port>
<txt-record>model=TimeCapsule8,119</txt-record>
</service>
<service>
<type>_adisk._tcp</type>
<txt-record>dk0=adVN=timemachine,adVF=0x82</txt-record>
<txt-record>sys=waMa=0,adVF=0x100</txt-record>
</service>
</service-group>
'';
};
};
};
}
@@ -1,89 +0,0 @@
{
pkgs,
config,
lib,
...
}: let
service = "syncthing";
cfg = config.holocron.${service};
sec = config.sops.secrets;
url = "syncthing.snowbelle.blakedheld.xyz";
homelab = config.homelab;
in {
options.holocron.${service} = {
enable = lib.mkEnableOption "enables syncthing";
};
config = lib.mkIf cfg.enable {
services.syncthing = {
enable = true;
user = "blake";
group = "blake";
dataDir = "/var/lib/syncthing";
guiAddress = "0.0.0.0:2222";
openDefaultPorts = true;
#extraFlags = ["--no-default-folder"];
key = sec."${service}/snowbelle/key".path;
cert = sec."${service}/snowbelle/cert".path;
settings = {
devices = {
"mudkip" = {id = "OV4NUQK-3YHRL5R-SIZGTNL-7VZFFUX-FOJ6NTS-C7ROXR7-I2Q2W7G-QERO7AO";};
"zygarde" = {id = "UYLTF52-VVKUR7F-JN33HQZ-RFNWGL3-JER52LA-GZD2LPJ-QIFEE7K-MNMZRQ5";};
"yveltal" = {id = "ZVSQ4WJ-7OICYOZ-3ECES4X-KH37IPB-TKHKUJG-BSEGXVM-AHYY5C3-VKG44AX";};
"CEN-IT-07" = {id = "DPYKA4Z-3PX7JB2-FBEOXXX-SC7TLT2-QC5P2IR-SXOPJGX-QO3DMII-5B7UCA4";};
"CEN-IT-00007" = {id = "XBPXGYU-DUJSLDH-6BDNF4D-CO2COC3-N3FM6W5-IHZOJBM-Z2N77RI-IVAV5AH";};
};
folders = {
"holocron" = {
path = "/holocron/users/blake/holocron";
devices = ["mudkip" "zygarde" "CEN-IT-07" "CEN-IT-00007" "yveltal"];
id = "5voxg-c3he2";
versioning = {
type = "staggered";
fsPath = "/holocron/users/blake/holocron/.stversions";
params = {
cleanInterval = "3600";
maxAge = "0";
};
};
};
};
options = {
urAccepted = -1;
};
};
};
sops.secrets = {
"${service}/snowbelle/key" = {
owner = "blake";
group = "blake";
};
"${service}/snowbelle/cert" = {
owner = "blake";
group = "blake";
};
};
homelab.backups.baks = {
${service} = {paths = [config.services.syncthing.dataDir];};
};
services.caddy.virtualHosts."${url}" = {
extraConfig = ''
tls internal
reverse_proxy 127.0.0.1:2222
'';
};
# add to glance (local service)
homelab.glance.links.system = [
{
title = service;
url = "https://${url}";
error-url = "http://${homelab.host_ip}:2222";
check-url = "http://${homelab.host_ip}:2222";
icon = "di:${service}";
}
];
};
}
@@ -1,79 +0,0 @@
{
pkgs,
config,
lib,
...
}: let
cfg = config.holocron.zfs;
in {
options.holocron.zfs = {
enable = lib.mkEnableOption "enables zfs";
};
config = lib.mkIf cfg.enable {
# set network host id
networking.hostId = "3e6e7055";
# enable zfs support
boot.zfs.forceImportRoot = false;
boot.kernelModules = ["zfs"];
boot.supportedFilesystems = ["zfs"];
# arc cache size
boot.kernelParams = ["zfs.zfs_arc_max=12884901888"];
# pools to import
#boot.zfs.extraPools = [ "holocron" "holocron/archives" "/holocron/media" "/holocron/users" ];
#boot.zfs.extraPools = [ "holocron" ];
# enable smart monitoring
services.smartd = {
enable = true;
autodetect = true;
defaults.monitored = "-a -o on -s (S/../.././05|L/../01/./05)";
notifications.mail = {
enable = true;
sender = "zfs@snowbelle.lan";
};
};
# enable zfs
services.zfs = {
autoScrub.enable = true;
autoScrub.interval = "weekly";
# email notifs
zed = {
enableMail = false;
settings = {
ZED_EMAIL_ADDR = ["root"];
# send notification if scrub succeeds
ZED_NOTIFY_VERBOSE = true;
};
};
};
# install userspace tools for acl's
environment.systemPackages = with pkgs; [smartmontools];
fileSystems."/holocron" = {
device = "holocron";
fsType = "zfs";
options = ["nofail"];
};
fileSystems."/holocron/archives" = {
device = "holocron/archives";
fsType = "zfs";
options = ["nofail"];
};
fileSystems."/holocron/users" = {
device = "holocron/users";
fsType = "zfs";
options = ["nofail"];
};
fileSystems."/holocron/media" = {
device = "holocron/media";
fsType = "zfs";
options = ["nofail"];
};
};
}
+7 -2
View File
@@ -16,6 +16,11 @@
./perms ./perms
]; ];
# define the groups used for backups and archives # # define the groups used for backups and archives
users.groups.archives = {gid = 727;}; # users.users.archives = {
# isSystemUser = true;
# group = "archives";
# };
#
# users.groups.archives = {gid = 727;};
} }
+15 -1
View File
@@ -34,7 +34,7 @@ let
}; };
timemachine = { timemachine = {
browseable = true; browseable = true;
"path" = "/holocron/timemachine"; "path" = "/holocron/archives/timemachine";
"valid users" = "blake"; "valid users" = "blake";
"public" = "no"; "public" = "no";
"writeable" = "yes"; "writeable" = "yes";
@@ -66,6 +66,20 @@ let
"create mask" = "0775"; "create mask" = "0775";
"directory mask" = "0775"; "directory mask" = "0775";
}; };
nvr = {
path = "/holocron/nvr";
writable = true;
guestOk = false;
browseable = true;
"valid users" = "archives";
"public" = "no";
"writeable" = "yes";
"force user" = "archives";
# time machine specifc config
"create mask" = "0660";
"directory mask" = "0770";
"force group" = "archives";
};
}; };
in { in {
options.holocron.smb = { options.holocron.smb = {
@@ -31,21 +31,21 @@ in {
"zygarde" = {id = "UYLTF52-VVKUR7F-JN33HQZ-RFNWGL3-JER52LA-GZD2LPJ-QIFEE7K-MNMZRQ5";}; "zygarde" = {id = "UYLTF52-VVKUR7F-JN33HQZ-RFNWGL3-JER52LA-GZD2LPJ-QIFEE7K-MNMZRQ5";};
"yveltal" = {id = "ZVSQ4WJ-7OICYOZ-3ECES4X-KH37IPB-TKHKUJG-BSEGXVM-AHYY5C3-VKG44AX";}; "yveltal" = {id = "ZVSQ4WJ-7OICYOZ-3ECES4X-KH37IPB-TKHKUJG-BSEGXVM-AHYY5C3-VKG44AX";};
"CEN-IT-07" = {id = "DPYKA4Z-3PX7JB2-FBEOXXX-SC7TLT2-QC5P2IR-SXOPJGX-QO3DMII-5B7UCA4";}; "CEN-IT-07" = {id = "DPYKA4Z-3PX7JB2-FBEOXXX-SC7TLT2-QC5P2IR-SXOPJGX-QO3DMII-5B7UCA4";};
"CEN-IT-00007" = {id = "XBPXGYU-DUJSLDH-6BDNF4D-CO2COC3-N3FM6W5-IHZOJBM-Z2N77RI-IVAV5AH";}; "CEN-IT-00007" = {id = "UEWNSUZ-AX75M5Y-OA4FURY-ORMEXFA-XUXU4LU-LEUYKVW-IDM2GQC-4UR4YAL";};
}; };
folders = { folders = {
"holocron" = { "holocron" = {
path = "/holocron/users/blake/holocron"; path = "/holocron/users/blake/holocron";
devices = ["piplup" "zygarde" "CEN-IT-07" "CEN-IT-00007" "yveltal"]; devices = ["piplup" "zygarde" "CEN-IT-07" "CEN-IT-00007" "yveltal"];
id = "5voxg-c3he2"; id = "5voxg-c3he2";
versioning = { # versioning = {
type = "staggered"; # type = "staggered";
fsPath = "/holocron/users/blake/holocron/.stversions"; # fsPath = "/holocron/users/blake/holocron/.stversions";
params = { # params = {
cleanInterval = "3600"; # cleanInterval = "3600";
maxAge = "0"; # maxAge = "0";
}; # };
}; # };
}; };
}; };
options = { options = {
@@ -8,8 +8,12 @@
cfg = config.gameservers.${service}; cfg = config.gameservers.${service};
sec = config.sops.secrets; sec = config.sops.secrets;
servers = { servers = {
cobblemon = { # cobblemon = {
data_dir = "/var/lib/gameservers/minecraft_modded/cobblemon"; # data_dir = "/var/lib/gameservers/minecraft_modded/cobblemon";
# start_file = "start.sh";
# };
linggango = {
data_dir = "/var/lib/gameservers/minecraft_modded/linggango";
start_file = "start.sh"; start_file = "start.sh";
}; };
}; };
@@ -18,7 +22,7 @@ in {
enable = lib.mkEnableOption "enables ${service}"; enable = lib.mkEnableOption "enables ${service}";
url = lib.mkOption { url = lib.mkOption {
type = lib.types.str; type = lib.types.str;
default = "mc.recoil.pro"; default = "modded.recoil.pro";
description = "set domain for ${service}"; description = "set domain for ${service}";
}; };
data_dir = lib.mkOption { data_dir = lib.mkOption {
@@ -38,16 +42,33 @@ in {
}; };
motd_gs = lib.mkOption { motd_gs = lib.mkOption {
type = lib.types.nullOr lib.types.str; type = lib.types.nullOr lib.types.str;
default = ["cobblemon"]; default = ["craftoria"];
}; };
backup_repo = lib.mkOption { backup_repo = lib.mkOption {
type = lib.types.path; type = lib.types.path;
default = "/holocron/archives/gameservers/minecraft/modded"; default = "/var/backup/gameservers/minecraft/modded";
description = "path to take hourly backups to with borg!"; description = "path to take hourly backups to with borg!";
}; };
offsite_user = lib.mkOption {
type = lib.types.str;
default = "lifeboat";
description = "user to connect to offsite host with";
};
offsite_target = lib.mkOption {
type = lib.types.str;
default = "lifeboat.holocron.blue";
description = "ip or domain for offsite backups";
};
offsite_dir = lib.mkOption {
type = lib.types.str;
default = "lifeboat/holocron/archives/gameservers";
description = "path to rsync offsite backups to";
};
}; };
config = lib.mkIf cfg.enable { config = lib.mkIf cfg.enable {
users.groups.minecraft = {gid = lib.mkForce cfg.ids;};
# declare ${service} user # declare ${service} user
users.users.minecraft = lib.mkDefault { users.users.minecraft = lib.mkDefault {
description = "minecraft server user"; description = "minecraft server user";
@@ -70,13 +91,15 @@ in {
description = "minecraft_recpro: ${name}"; description = "minecraft_recpro: ${name}";
after = ["network.target"]; after = ["network.target"];
wants = ["network.target"]; wants = ["network.target"];
path = [pkgs.openjdk21];
serviceConfig = { serviceConfig = {
User = "minecraft"; User = "minecraft";
Group = "minecraft"; Group = "minecraft";
WorkingDirectory = srv.data_dir; WorkingDirectory = srv.data_dir;
UMask = "0007"; UMask = "0007";
ExecStart = "${pkgs.openjdk21}/bin/java -Xms4G -Xmx12G -XX:+UseG1GC -XX:+ParallelRefProcEnabled -XX:MaxGCPauseMillis=200 -XX:+UnlockExperimentalVMOptions -XX:+AlwaysPreTouch -XX:G1NewSizePercent=30 -XX:G1MaxNewSizePercent=40 -XX:G1HeapRegionSize=8M -XX:G1ReservePercent=20 -XX:G1HeapWastePercent=5 -XX:G1MixedGCCountTarget=4 -XX:InitiatingHeapOccupancyPercent=15 -XX:G1MixedGCLiveThresholdPercent=90 -XX:G1RSetUpdatingPauseTimePercent=5 -XX:SurvivorRatio=32 -XX:+PerfDisableSharedMem -XX:MaxTenuringThreshold=1 -Dusing.aikars.flags=https://mcflags.emc.gs -Daikars.new.flags=true @libraries/net/neoforged/neoforge/21.1.211/unix_args.txt"; #ExecStart = "${pkgs.openjdk21}/bin/java -Xms4G -Xmx12G -XX:+UseG1GC -XX:+ParallelRefProcEnabled -XX:MaxGCPauseMillis=200 -XX:+UnlockExperimentalVMOptions -XX:+AlwaysPreTouch -XX:G1NewSizePercent=30 -XX:G1MaxNewSizePercent=40 -XX:G1HeapRegionSize=8M -XX:G1ReservePercent=20 -XX:G1HeapWastePercent=5 -XX:G1MixedGCCountTarget=4 -XX:InitiatingHeapOccupancyPercent=15 -XX:G1MixedGCLiveThresholdPercent=90 -XX:G1RSetUpdatingPauseTimePercent=5 -XX:SurvivorRatio=32 -XX:+PerfDisableSharedMem -XX:MaxTenuringThreshold=1 -Dusing.aikars.flags=https://mcflags.emc.gs -Daikars.new.flags=true @libraries/net/neoforged/neoforge/21.1.211/unix_args.txt";
#ExecStart = "${srv.data_dir}/${srv.start_file}"; #ExecStart = "${srv.data_dir}/${srv.start_file}";
ExecStart = "${pkgs.openjdk21}/bin/java -Xms4G -Xmx24G @libraries/net/minecraftforge/forge/1.20.1-47.4.20/unix_args.txt \"$@\"";
Restart = "on-failure"; Restart = "on-failure";
KillMode = "process"; KillMode = "process";
}; };
@@ -84,7 +107,7 @@ in {
}) })
servers; servers;
environment.systemPackages = with pkgs; [openjdk21 mcrcon]; environment.systemPackages = with pkgs; [openjdk21 mcrcon borgbackup sshpass tree rsync];
# services.mysql = { # services.mysql = {
# enable = true; # enable = true;
@@ -104,20 +127,23 @@ in {
# }; # };
# open firewall # open firewall
networking.firewall.allowedTCPPorts = [25778]; networking.firewall.allowedTCPPorts = [25579];
networking.firewall.allowedUDPPorts = [25580]; #voicechat
# sops.secrets = { sops.secrets = {
# "velocity_forwarding" = { "borg_passwd" = {
# owner = "minecraft"; owner = "root";
# group = "minecraft"; group = "root";
# path = "/var/lib/gameservers/minecraft_recpro/velocity/forwarding.secret"; };
# mode = "0400"; "lifeboat_rsync" = {
# }; owner = "root";
# "minecraft_recpro_db_passwd" = { group = "archives";
# owner = "mysql"; mode = "0440";
# group = "mysql"; };
# }; };
# };
# helpful and for scripts
users.groups.archives = {gid = 727;};
# backups minecraft_modded with borg! # backups minecraft_modded with borg!
services.borgbackup.jobs.${service} = { services.borgbackup.jobs.${service} = {
@@ -137,6 +163,13 @@ in {
); );
compression = "auto,zstd"; compression = "auto,zstd";
#preHook = "systemctl start mysql-backup.service"; #preHook = "systemctl start mysql-backup.service";
postHook = ''
${pkgs.sshpass}/bin/sshpass -f ${sec."lifeboat_rsync".path} \
${pkgs.rsync}/bin/rsync -aHAX --partial --numeric-ids --info=progress2,name1,stats2 --delete \
-e "ssh -o StrictHostKeyChecking=no" \
${toString cfg.backup_repo} \
${cfg.offsite_user}@${cfg.offsite_target}::${cfg.offsite_dir}
'';
startAt = "*-*-* *:00:00"; startAt = "*-*-* *:00:00";
group = "archives"; group = "archives";
encryption.mode = "repokey-blake2"; encryption.mode = "repokey-blake2";
+149
View File
@@ -0,0 +1,149 @@
{
pkgs,
config,
lib,
inputs,
...
}: let
nixservice = "podman-valheim";
service = "valheim";
cfg = config.gameservers.${service};
sec = config.sops.secrets;
homelab = config.homelab;
in {
options.gameservers.${service} = {
enable = lib.mkEnableOption "enables ${service}";
# set port options
port = lib.mkOption {
type = lib.types.int;
default = 2456;
description = "set port for ${service} (default: ${toString cfg.port}";
};
url = lib.mkOption {
type = lib.types.str;
default = "${service}.${homelab.base_domain}";
description = "set domain for ${service}";
};
data_dir = lib.mkOption {
type = lib.types.str;
default = "/var/lib/gameservers/${service}";
description = "set data directory for ${service}";
};
ids = lib.mkOption {
type = lib.types.int;
default = cfg.port;
description = "set uid and pid of ${service} user (matches port by default)";
};
motd_gs = lib.mkOption {
type = lib.types.nullOr (lib.types.listOf lib.types.str);
default = ["podman-valheim"];
};
backup = lib.mkOption {
type = lib.types.bool;
default = false;
description = "enable backups for ${service}";
};
backup_repo = lib.mkOption {
type = lib.types.path;
default = "/var/backup/gameservers/valheim";
description = "path to take hourly backups to with borg!";
};
offsite_user = lib.mkOption {
type = lib.types.str;
default = "lifeboat";
description = "user to connect to offsite host with";
};
offsite_target = lib.mkOption {
type = lib.types.str;
default = "lifeboat.holocron.blue";
description = "ip or domain for offsite backups";
};
offsite_dir = lib.mkOption {
type = lib.types.str;
default = "lifeboat/holocron/archives/gameservers";
description = "path to rsync offsite backups to";
};
};
config = lib.mkIf cfg.enable {
# declare ${service} group
users.groups.${service} = {gid = lib.mkForce cfg.ids;};
# declare ${service} user
users.users.${service} = {
description = "${service} server user";
uid = lib.mkForce cfg.ids;
isSystemUser = true;
home = cfg.data_dir;
createHome = true;
group = service;
extraGroups = [];
};
virtualisation.oci-containers.containers = {
${service} = {
image = "ghcr.io/community-valheim-tools/valheim-server";
autoStart = true;
extraOptions = [
"--cap-add=sys_nice"
"--stop-timeout=120"
];
ports = [
"2456-2457:2456-2457/udp"
"2456:80/tcp"
];
volumes = [
"${cfg.data_dir}/config:/config"
"${cfg.data_dir}/data:/opt/valheim"
];
environment = {
SERVER_NAME = "recpro";
SERVER_PASS = "recoil727pro";
#WORLD_NAME = "";
STATUS_HTTP = "true";
TZ = homelab.tz;
PUID = toString config.users.users.${service}.uid;
PGID = toString config.users.groups.${service}.gid;
};
};
};
# override umask to make permissions work out
systemd.services.${service}.serviceConfig = {
UMask = lib.mkForce "0007";
};
# open firewall
networking.firewall.allowedTCPPorts = [cfg.port];
networking.firewall.allowedUDPPorts = [2456 2457];
# backups valhiem with borg!
services.borgbackup.jobs.${service} = {
archiveBaseName = service;
repo = cfg.backup_repo;
paths = cfg.data_dir;
compression = "auto,zstd";
#preHook = "systemctl start mysql-backup.service";
postHook = ''
${pkgs.sshpass}/bin/sshpass -f ${sec."lifeboat_rsync".path} \
${pkgs.rsync}/bin/rsync -aHAX --partial --numeric-ids --info=progress2,name1,stats2 --delete \
-e "ssh -o StrictHostKeyChecking=no" \
${toString cfg.backup_repo} \
${cfg.offsite_user}@${cfg.offsite_target}::${cfg.offsite_dir}
'';
startAt = "*-*-* *:00:00";
group = "archives";
encryption.mode = "repokey-blake2";
encryption.passCommand = "cat ${config.sops.secrets."borg_passwd".path}";
extraArgs = ["--verbose" "--show-rc" "--umask" "0007"];
extraCreateArgs = ["--list" "--stats" "--filter" "AME"];
prune.keep = {
within = "1d"; # Keep all archives from the last day
hourly = 24;
daily = 7;
weekly = 12;
monthly = -1; # Keep at least one archive for each month
};
};
};
}
+29
View File
@@ -0,0 +1,29 @@
{
pkgs,
config,
lib,
...
}: let
cfg = config.homelab.nomad;
in {
options.homelab.nomad = {
enable = lib.mkEnableOption "enable in house project nomad";
tz = lib.mkOption {
default = "America/Chicago";
type = lib.types.str;
description = "set timezone";
};
};
config = lib.mkIf cfg.enable {
# the order determines the order in glance :3
imports = [
./kiwix
./maps
./kolibri
];
homelab.kiwix.enable = lib.mkDefault true;
homelab.maps.enable = lib.mkDefault true;
homelab.kolibri.enable = lib.mkDefault true;
};
}
+121
View File
@@ -0,0 +1,121 @@
{
pkgs,
config,
lib,
...
}: let
service = "kiwix";
cfg = config.homelab.${service};
sec = config.sops.secrets;
homelab = config.homelab;
in {
options.homelab.${service} = {
enable = lib.mkEnableOption "enables ${service}";
# set port options
port = lib.mkOption {
type = lib.types.int;
default = 7730;
description = "set port for ${service} (default: ${toString cfg.port}";
};
url = lib.mkOption {
type = lib.types.str;
default = "${service}.${homelab.base_domain}";
description = "set domain for ${service}";
};
data_dir = lib.mkOption {
type = lib.types.str;
default = "/var/lib/${service}";
description = "set data directory for ${service}";
};
ids = lib.mkOption {
type = lib.types.int;
default = cfg.port;
description = "set uid and pid of ${service} user (matches port by default)";
};
backup = lib.mkOption {
type = lib.types.bool;
default = true;
description = "enable backups for ${service}";
};
motd = lib.mkOption {
type = lib.types.nullOr lib.types.str;
default = "kiwix-serve";
};
};
config = lib.mkIf cfg.enable {
# declare ${service} group
users.groups.${service} = {
gid = lib.mkForce cfg.ids;
};
# declare ${service} user
users.users.${service} = {
description = "${service} server user";
uid = lib.mkForce cfg.ids;
isSystemUser = true;
home = cfg.data_dir;
createHome = true;
group = service;
extraGroups = ["media"];
};
# helpful and for scripts
environment.systemPackages = with pkgs; [kiwix-tools];
# enable the ${service} service
services.kiwix-serve = {
enable = true;
openFirewall = true;
port = cfg.port;
user = service;
group = service;
libraryPath = "${cfg.data_dir}/library.xml";
extraArgs = {
};
};
# override umask to make permissions work out
systemd.services.${service}.serviceConfig = {
UMask = lib.mkForce "0007";
User = service;
Group = service;
};
# add to caddy for reverse proxy
services.caddy.virtualHosts."${cfg.url}" = {
serverAliases = ["${service}.${homelab.public_domain}"];
# use explicitly defined tls cert
# tls /etc/ssl/blakedheld.xyz.crt /etc/ssl/blakedheld.xyz.key
extraConfig = ''
tls internal
reverse_proxy 127.0.0.1:${toString cfg.port}
'';
};
# add to glance (local service)
homelab.glance.links.nomad = [
{
title = service;
url = "https://${cfg.url}";
error-url = "http://${homelab.host_ip}:${toString cfg.port}";
check-url = "http://${homelab.host_ip}:${toString cfg.port}";
icon = "di:${service}";
}
];
# sops.secrets = {
# "${service}_" = {
# owner = ;
# group = ;
# };
# };
# add to backups
homelab.backups.baks = {
${service} = {
paths = [cfg.data_dir];
};
};
};
}
+12
View File
@@ -2,6 +2,7 @@
pkgs, pkgs,
config, config,
lib, lib,
inputs,
... ...
}: let }: let
cfg = config.homelab; cfg = config.homelab;
@@ -36,6 +37,17 @@ in {
./mediastack ./mediastack
./services ./services
./system ./system
#./nomad
./network ./network
]; ];
config = lib.mkIf cfg.enable {
# define the groups used for backups and archives
users.users.archives = {
isSystemUser = true;
group = "archives";
};
users.groups.archives = {gid = 727;};
};
} }
+9 -5
View File
@@ -27,13 +27,15 @@ in {
# the order determines the order in glance :3 # the order determines the order in glance :3
imports = [ imports = [
./bazarr
./prowlarr
./radarr
./qbittorrent
./sonarr
./yacreader ./yacreader
./bazarr
./qbittorrent
./prowlarr
./lidarr
./radarr
./sonarr
./audiobookshelf ./audiobookshelf
./navidrome
./jellyfin ./jellyfin
./flaresolverr ./flaresolverr
]; ];
@@ -56,7 +58,9 @@ in {
homelab.prowlarr.enable = lib.mkDefault true; homelab.prowlarr.enable = lib.mkDefault true;
homelab.radarr.enable = lib.mkDefault true; homelab.radarr.enable = lib.mkDefault true;
homelab.sonarr.enable = lib.mkDefault true; homelab.sonarr.enable = lib.mkDefault true;
homelab.lidarr.enable = lib.mkDefault true;
homelab.audiobookshelf.enable = lib.mkDefault true; homelab.audiobookshelf.enable = lib.mkDefault true;
homelab.navidrome.enable = lib.mkDefault true;
homelab.flaresolverr.enable = lib.mkDefault true; homelab.flaresolverr.enable = lib.mkDefault true;
}; };
} }
@@ -7,6 +7,7 @@
service = "jellyfin"; service = "jellyfin";
cfg = config.homelab.${service}; cfg = config.homelab.${service};
homelab = config.homelab; homelab = config.homelab;
host = config.networking.hostName;
in { in {
options.homelab.${service} = { options.homelab.${service} = {
enable = lib.mkEnableOption "enables ${service}"; enable = lib.mkEnableOption "enables ${service}";
@@ -61,6 +62,7 @@ in {
# enable the ${service} service # enable the ${service} service
services.${service} = { services.${service} = {
enable = true; enable = true;
package = pkgs.unstable.jellyfin;
openFirewall = true; openFirewall = true;
user = service; user = service;
group = service; group = service;
@@ -85,7 +87,7 @@ in {
homelab.glance.links.mediastack = [ homelab.glance.links.mediastack = [
{ {
title = service; title = service;
url = "https://media.${homelab.public_domain}"; url = "https://media.${host}.${homelab.public_domain}";
error-url = "http://${homelab.host_ip}:${toString cfg.port}"; error-url = "http://${homelab.host_ip}:${toString cfg.port}";
check-url = "http://${homelab.host_ip}:${toString cfg.port}"; check-url = "http://${homelab.host_ip}:${toString cfg.port}";
icon = "di:${service}"; icon = "di:${service}";
@@ -0,0 +1,108 @@
{
pkgs,
config,
lib,
...
}: let
service = "lidarr";
cfg = config.homelab.${service};
sec = config.sops.secrets;
homelab = config.homelab;
in {
options.homelab.${service} = {
enable = lib.mkEnableOption "enables ${service}";
# set port options
port = lib.mkOption {
type = lib.types.int;
default = 7109;
description = "set port for ${service} (default: ${toString cfg.port}";
};
url = lib.mkOption {
type = lib.types.str;
default = "${service}.${homelab.base_domain}";
description = "set domain for ${service}";
};
data_dir = lib.mkOption {
type = lib.types.str;
default = "/var/lib/${service}";
description = "set data directory for ${service}";
};
ids = lib.mkOption {
type = lib.types.int;
default = cfg.port;
description = "set uid and pid of ${service} user (matches port by default)";
};
backup = lib.mkOption {
type = lib.types.bool;
default = true;
description = "enable backups for ${service}";
};
motd = lib.mkOption {
type = lib.types.nullOr lib.types.str;
default = service;
};
};
config = lib.mkIf cfg.enable {
# required
environment.systemPackages = with pkgs; [ffmpeg_6-headless yt-dlp];
# declare ${service} group
users.groups.${service} = {gid = lib.mkForce cfg.ids;};
# declare ${service} user
users.users.${service} = {
description = "${service} server user";
uid = lib.mkForce cfg.ids;
isSystemUser = true;
home = cfg.data_dir;
createHome = true;
group = service;
extraGroups = ["media"];
};
# enable the ${service} service
services.${service} = {
enable = true;
openFirewall = true;
user = service;
group = service;
dataDir = cfg.data_dir;
settings = {
server.port = cfg.port;
};
};
# override umask to make permissions work out
systemd.services.${service}.serviceConfig = {
UMask = lib.mkForce "0007";
# User = service;
# Group = service;
};
# add to caddy for reverse proxy
services.caddy.virtualHosts."${cfg.url}" = {
extraConfig = ''
tls internal
reverse_proxy 127.0.0.1:${toString cfg.port}
'';
};
# add to glance
homelab.glance.links.mediastack = [
{
title = service;
url = "https://${cfg.url}";
error-url = "http://${homelab.host_ip}:${toString cfg.port}";
check-url = "http://${homelab.host_ip}:${toString cfg.port}";
icon = "di:${service}";
}
];
# add to backups
homelab.backups.baks = {
${service} = {paths = [cfg.data_dir];};
};
};
}
@@ -0,0 +1,115 @@
{
pkgs,
config,
lib,
...
}: let
service = "navidrome";
cfg = config.homelab.${service};
homelab = config.homelab;
in {
options.homelab.${service} = {
enable = lib.mkEnableOption "enables ${service}";
# set port options
port = lib.mkOption {
type = lib.types.int;
default = 7108;
description = "set port for ${service} (default: ${toString cfg.port}";
};
url = lib.mkOption {
type = lib.types.str;
default = "music.${homelab.base_domain}";
description = "set domain for ${service}";
};
data_dir = lib.mkOption {
type = lib.types.str;
default = "/var/lib/${service}";
description = "set data directory for ${service}";
};
ids = lib.mkOption {
type = lib.types.int;
default = cfg.port;
description = "set uid and pid of ${service} user (matches port by default)";
};
backup = lib.mkOption {
type = lib.types.bool;
default = true;
description = "enable backups for ${service}";
};
motd = lib.mkOption {
type = lib.types.nullOr lib.types.str;
default = service;
};
};
config = lib.mkIf cfg.enable {
# declare ${service} group
users.groups.${service} = {gid = lib.mkForce cfg.ids;};
# declare ${service} user
users.users.${service} = {
description = "${service} server user";
uid = lib.mkForce cfg.ids;
isSystemUser = true;
# home = cfg.data_dir;
createHome = true;
group = service;
extraGroups = ["media"];
};
# enable the ${service} service
services.${service} = {
enable = true;
openFirewall = true;
user = service;
group = service;
# plugins = [
# ];
environmentFile = "${cfg.data_dir}/navidrome.env";
settings = {
Address = "0.0.0.0";
Port = cfg.port;
MusicFolder = "/holocron/media/music";
EnableInsightsCollector = false;
LyricsPriority = "nd-lyrics";
Plugins = {
Enabled = true;
#Folder = lib.mkForce "${cfg.data_dir}/plugins";
};
};
};
# override umask to make permissions work out
systemd.services.${service}.serviceConfig = {
UMask = lib.mkForce "0007";
EnvironmentFile = "${cfg.data_dir}/navidrome.env";
};
# add to caddy for reverse proxy
services.caddy.virtualHosts."${cfg.url}" = {
#serverAliases = ["abs.${homelab.public_domain}"];
extraConfig = ''
tls internal
reverse_proxy 127.0.0.1:${toString cfg.port} {
}
'';
};
# add to glance public service
homelab.glance.links.mediastack = [
{
title = service;
url = "https://music.${homelab.base_domain}";
error-url = "http://${homelab.host_ip}:${toString cfg.port}";
check-url = "http://${homelab.host_ip}:${toString cfg.port}";
icon = "di:${service}";
}
];
# add to backups
homelab.backups.baks = {
${service} = {paths = [cfg.data_dir];};
};
};
}
+21 -3
View File
@@ -20,7 +20,7 @@ in {
}; };
keys = lib.mkOption { keys = lib.mkOption {
type = lib.types.bool; type = lib.types.bool;
default = true; default = false;
description = "host keys directory"; description = "host keys directory";
}; };
backup = lib.mkOption { backup = lib.mkOption {
@@ -54,13 +54,23 @@ in {
user = service; user = service;
group = service; group = service;
dataDir = cfg.data_dir; dataDir = cfg.data_dir;
package = pkgs.caddy.withPlugins {
plugins = [
"github.com/caddy-dns/cloudflare@v0.2.4"
];
hash = "sha256-dQvk6ezY6TQ1J7PjhCXnThF/SqVgPwBO8/RXzHCY+js=";
# Replace with the hash from the build error the first time you build.
};
email = "me@blakedheld.xyz"; email = "me@blakedheld.xyz";
globalConfig = '' globalConfig = ''
auto_https ignore_loaded_certs auto_https ignore_loaded_certs
acme_dns cloudflare {env.CLOUDFLARE_API_TOKEN}
''; '';
# static page for hosting key files # static page for hosting key files
virtualHosts."keys.${homelab.base_domain}" = { virtualHosts = {
"keys.${homelab.base_domain}" = lib.mkIf cfg.keys {
serverAliases = ["keys.${homelab.public_domain}"]; serverAliases = ["keys.${homelab.public_domain}"];
extraConfig = '' extraConfig = ''
tls internal tls internal
@@ -69,6 +79,7 @@ in {
''; '';
}; };
}; };
};
# enable acme for auto ssl certs with lets encrypt # enable acme for auto ssl certs with lets encrypt
security.acme = { security.acme = {
@@ -79,6 +90,9 @@ in {
# override umask to make permissions work out # override umask to make permissions work out
systemd.services.${service}.serviceConfig = { systemd.services.${service}.serviceConfig = {
UMask = lib.mkForce "0007"; UMask = lib.mkForce "0007";
# make cloudflare token readable
EnvironmentFile = sec."cloudflare/api_token_caddy".path;
#LoadCredential = "CLOUDFLARE_API_TOKEN:${sec."cloudflare/api_token_caddy".path}";
}; };
# open firewall # open firewall
@@ -95,6 +109,10 @@ in {
group = "caddy"; group = "caddy";
path = "/etc/ssl/blakedheld.xyz.key"; path = "/etc/ssl/blakedheld.xyz.key";
}; };
"cloudflare/api_token_caddy" = {
owner = "caddy";
group = "caddy";
};
"klefki_pub.asc" = { "klefki_pub.asc" = {
owner = "caddy"; owner = "caddy";
group = "caddy"; group = "caddy";
@@ -112,7 +130,7 @@ in {
<html> <html>
<head> <head>
<meta charset="utf-8"> <meta charset="utf-8">
<title>{{html .Name}}</title> <title>keyring</title>
<style> <style>
footer { display: none !important; } footer { display: none !important; }
</style> </style>
+12 -6
View File
@@ -29,17 +29,23 @@ in {
"superflat.recoil.pro" "superflat.recoil.pro"
"skyblock.recoil.pro" "skyblock.recoil.pro"
"cobblemon.recoil.pro" "cobblemon.recoil.pro"
"valheim.recoil.pro"
# blakedheld.xyz # blakedheld.xyz
"blakedheld.xyz" #"blakedheld.xyz"
"*.blakedheld.xyz" #"*.blakedheld.xyz"
"git.blakedheld.xyz" #"git.blakedheld.xyz"
"up.blakedheld.xyz" #"up.blakedheld.xyz"
# holocron.blue # holocron.blue
"holocron.blue" #"holocron.blue"
"*.holocron.blue" #"*.holocron.blue"
"git.holocron.blue" "git.holocron.blue"
"pass.holocron.blue"
"photos.holocron.blue"
"media.holocron.blue"
"up.holocron.blue"
# mc servers
"mine.holocron.blue" "mine.holocron.blue"
"smp.holocron.blue" "smp.holocron.blue"
"skyblock.holocron.blue" "skyblock.holocron.blue"
@@ -23,7 +23,7 @@ in {
useRoutingFeatures = "both"; useRoutingFeatures = "both";
authKeyFile = sec."tailscale_authkey".path; authKeyFile = sec."tailscale_authkey".path;
extraSetFlags = [ extraSetFlags = [
"--advertise-routes=${config.homelab.host_ip}/32" # advertise self "--advertise-routes=${config.homelab.host_ip}/32,10.10.0.1/32,10.10.0.5/32,10.10.0.10/32" # advertise self
"--accept-routes=false" # true is equilivant to useRoutingFeatures = "client" (breaks shit) "--accept-routes=false" # true is equilivant to useRoutingFeatures = "client" (breaks shit)
"--accept-dns=true" # explicitly allow resolved "--accept-dns=true" # explicitly allow resolved
]; ];
+1
View File
@@ -11,6 +11,7 @@
./vaultwarden ./vaultwarden
./gitea ./gitea
./immich ./immich
./homebox
#./searxng #./searxng
]; ];
} }
+91 -12
View File
@@ -77,6 +77,11 @@ in {
default = []; default = [];
description = "list of links for ${service}"; description = "list of links for ${service}";
}; };
network = lib.mkOption {
type = lib.types.listOf lib.types.attrs;
default = [];
description = "list of links for ${service}";
};
}; };
}; };
@@ -244,6 +249,12 @@ in {
title = "system"; title = "system";
sites = cfg.links.system; sites = cfg.links.system;
} }
{
type = "monitor";
cache = "1m";
title = "network";
sites = cfg.links.network;
}
{ {
type = "custom-api"; type = "custom-api";
title = "recpro"; title = "recpro";
@@ -251,13 +262,13 @@ in {
cache = "5s"; cache = "5s";
template = "<div style=\"display:flex; align-items:center; gap:12px;\">\n <div style=\"width:40px; height:40px; flex-shrink:0; border-radius:4px; display:flex; justify-content:center; align-items:center; overflow:hidden;\">\n {{ if .JSON.Bool \"online\" }}\n <img src=\"{{ .JSON.String \"icon\" | safeURL }}\" width=\"64\" height=\"64\" style=\"object-fit:contain;\">\n {{ else }}\n <svg xmlns=\"http://www.w3.org/2000/svg\" viewBox=\"0 0 20 20\" fill=\"currentColor\" style=\"width:32px; height:32px; opacity:0.5;\">\n <path fill-rule=\"evenodd\" d=\"M1 5.25A2.25 2.25 0 0 1 3.25 3h13.5A2.25 2.25 0 0 1 19 5.25v9.5A2.25 2.25 0 0 1 16.75 17H3.25A2.25 2.25 0 0 1 1 14.75v-9.5Zm1.5 5.81v3.69c0 .414.336.75.75.75h13.5a.75.75 0 0 0 .75-.75v-2.69l-2.22-2.219a.75.75 0 0 0-1.06 0l-1.91 1.909.47.47a.75.75 0 1 1-1.06 1.06L6.53 8.091a.75.75 0 0 0-1.06 0l-2.97 2.97ZM12 7a1 1 0 1 1-2 0 1 1 0 0 1 2 0Z\" clip-rule=\"evenodd\" />\n </svg>\n {{ end }}\n </div>\n\n <div style=\"flex-grow:1; min-width:0;\">\n <a class=\"size-h4 block text-truncate color-highlight\">\n {{ .JSON.String \"host\" }}\n {{ if .JSON.Bool \"online\" }}\n <span\n style=\"width: 8px; height: 8px; border-radius: 50%; background-color: var(--color-positive); display: inline-block; vertical-align: middle;\"\n data-popover-type=\"text\"\n data-popover-text=\"Online\"\n ></span>\n {{ else }}\n <span\n style=\"width: 8px; height: 8px; border-radius: 50%; background-color: var(--color-negative); display: inline-block; vertical-align: middle;\"\n data-popover-type=\"text\"\n data-popover-text=\"Offline\"\n ></span>\n {{ end }}\n </a>\n\n <ul class=\"list-horizontal-text\">\n <li>\n {{ if .JSON.Bool \"online\" }}\n <span>{{ .JSON.String \"version.name_clean\" }}</span>\n {{ else }}\n <span>Offline</span>\n {{ end }}\n </li>\n {{ if .JSON.Bool \"online\" }}\n <li data-popover-type=\"html\">\n <div data-popover-html>\n {{ range .JSON.Array \"players.list\" }}{{ .String \"name_clean\" }}<br>{{ end }}\n </div>\n <p style=\"display:inline-flex;align-items:center;\">\n <svg xmlns=\"http://www.w3.org/2000/svg\" viewBox=\"0 0 24 24\" fill=\"currentColor\" class=\"size-6\" style=\"height:1em;vertical-align:middle;margin-right:0.5em;\">\n <path fill-rule=\"evenodd\" d=\"M7.5 6a4.5 4.5 0 1 1 9 0 4.5 4.5 0 0 1-9 0ZM3.751 20.105a8.25 8.25 0 0 1 16.498 0 .75.75 0 0 1-.437.695A18.683 18.683 0 0 1 12 22.5c-2.786 0-5.433-.608-7.812-1.7a.75.75 0 0 1-.437-.695Z\" clip-rule=\"evenodd\" />\n </svg>\n {{ .JSON.Int \"players.online\" | formatNumber }}/{{ .JSON.Int \"players.max\" | formatNumber }} players\n </p>\n </li>\n {{ else }}\n <li>\n <p style=\"display:inline-flex;align-items:center;\">\n <svg xmlns=\"http://www.w3.org/2000/svg\" viewBox=\"0 0 24 24\" fill=\"currentColor\" class=\"size-6\" style=\"height:1em;vertical-align:middle;margin-right:0.5em;opacity:0.5;\">\n <path fill-rule=\"evenodd\" d=\"M7.5 6a4.5 4.5 0 1 1 9 0 4.5 4.5 0 0 1-9 0ZM3.751 20.105a8.25 8.25 0 0 1 16.498 0 .75.75 0 0 1-.437.695A18.683 18.683 0 0 1 12 22.5c-2.786 0-5.433-.608-7.812-1.7a.75.75 0 0 1-.437-.695Z\" clip-rule=\"evenodd\" />\n </svg>\n 0 players\n </p>\n </li>\n {{ end }}\n </ul>\n </div>\n</div>"; template = "<div style=\"display:flex; align-items:center; gap:12px;\">\n <div style=\"width:40px; height:40px; flex-shrink:0; border-radius:4px; display:flex; justify-content:center; align-items:center; overflow:hidden;\">\n {{ if .JSON.Bool \"online\" }}\n <img src=\"{{ .JSON.String \"icon\" | safeURL }}\" width=\"64\" height=\"64\" style=\"object-fit:contain;\">\n {{ else }}\n <svg xmlns=\"http://www.w3.org/2000/svg\" viewBox=\"0 0 20 20\" fill=\"currentColor\" style=\"width:32px; height:32px; opacity:0.5;\">\n <path fill-rule=\"evenodd\" d=\"M1 5.25A2.25 2.25 0 0 1 3.25 3h13.5A2.25 2.25 0 0 1 19 5.25v9.5A2.25 2.25 0 0 1 16.75 17H3.25A2.25 2.25 0 0 1 1 14.75v-9.5Zm1.5 5.81v3.69c0 .414.336.75.75.75h13.5a.75.75 0 0 0 .75-.75v-2.69l-2.22-2.219a.75.75 0 0 0-1.06 0l-1.91 1.909.47.47a.75.75 0 1 1-1.06 1.06L6.53 8.091a.75.75 0 0 0-1.06 0l-2.97 2.97ZM12 7a1 1 0 1 1-2 0 1 1 0 0 1 2 0Z\" clip-rule=\"evenodd\" />\n </svg>\n {{ end }}\n </div>\n\n <div style=\"flex-grow:1; min-width:0;\">\n <a class=\"size-h4 block text-truncate color-highlight\">\n {{ .JSON.String \"host\" }}\n {{ if .JSON.Bool \"online\" }}\n <span\n style=\"width: 8px; height: 8px; border-radius: 50%; background-color: var(--color-positive); display: inline-block; vertical-align: middle;\"\n data-popover-type=\"text\"\n data-popover-text=\"Online\"\n ></span>\n {{ else }}\n <span\n style=\"width: 8px; height: 8px; border-radius: 50%; background-color: var(--color-negative); display: inline-block; vertical-align: middle;\"\n data-popover-type=\"text\"\n data-popover-text=\"Offline\"\n ></span>\n {{ end }}\n </a>\n\n <ul class=\"list-horizontal-text\">\n <li>\n {{ if .JSON.Bool \"online\" }}\n <span>{{ .JSON.String \"version.name_clean\" }}</span>\n {{ else }}\n <span>Offline</span>\n {{ end }}\n </li>\n {{ if .JSON.Bool \"online\" }}\n <li data-popover-type=\"html\">\n <div data-popover-html>\n {{ range .JSON.Array \"players.list\" }}{{ .String \"name_clean\" }}<br>{{ end }}\n </div>\n <p style=\"display:inline-flex;align-items:center;\">\n <svg xmlns=\"http://www.w3.org/2000/svg\" viewBox=\"0 0 24 24\" fill=\"currentColor\" class=\"size-6\" style=\"height:1em;vertical-align:middle;margin-right:0.5em;\">\n <path fill-rule=\"evenodd\" d=\"M7.5 6a4.5 4.5 0 1 1 9 0 4.5 4.5 0 0 1-9 0ZM3.751 20.105a8.25 8.25 0 0 1 16.498 0 .75.75 0 0 1-.437.695A18.683 18.683 0 0 1 12 22.5c-2.786 0-5.433-.608-7.812-1.7a.75.75 0 0 1-.437-.695Z\" clip-rule=\"evenodd\" />\n </svg>\n {{ .JSON.Int \"players.online\" | formatNumber }}/{{ .JSON.Int \"players.max\" | formatNumber }} players\n </p>\n </li>\n {{ else }}\n <li>\n <p style=\"display:inline-flex;align-items:center;\">\n <svg xmlns=\"http://www.w3.org/2000/svg\" viewBox=\"0 0 24 24\" fill=\"currentColor\" class=\"size-6\" style=\"height:1em;vertical-align:middle;margin-right:0.5em;opacity:0.5;\">\n <path fill-rule=\"evenodd\" d=\"M7.5 6a4.5 4.5 0 1 1 9 0 4.5 4.5 0 0 1-9 0ZM3.751 20.105a8.25 8.25 0 0 1 16.498 0 .75.75 0 0 1-.437.695A18.683 18.683 0 0 1 12 22.5c-2.786 0-5.433-.608-7.812-1.7a.75.75 0 0 1-.437-.695Z\" clip-rule=\"evenodd\" />\n </svg>\n 0 players\n </p>\n </li>\n {{ end }}\n </ul>\n </div>\n</div>";
} }
{ # {
type = "custom-api"; # type = "custom-api";
title = "cobblemon"; # title = "linggango";
url = "https://api.mcstatus.io/v2/status/java/cobblemon.recoil.pro"; # url = "https://api.mcstatus.io/v2/status/java/raceraskedforthisenjoyyall.recoil.pro";
cache = "5s"; # cache = "5s";
template = "<div style=\"display:flex; align-items:center; gap:12px;\">\n <div style=\"width:40px; height:40px; flex-shrink:0; border-radius:4px; display:flex; justify-content:center; align-items:center; overflow:hidden;\">\n {{ if .JSON.Bool \"online\" }}\n <img src=\"{{ .JSON.String \"icon\" | safeURL }}\" width=\"64\" height=\"64\" style=\"object-fit:contain;\">\n {{ else }}\n <svg xmlns=\"http://www.w3.org/2000/svg\" viewBox=\"0 0 20 20\" fill=\"currentColor\" style=\"width:32px; height:32px; opacity:0.5;\">\n <path fill-rule=\"evenodd\" d=\"M1 5.25A2.25 2.25 0 0 1 3.25 3h13.5A2.25 2.25 0 0 1 19 5.25v9.5A2.25 2.25 0 0 1 16.75 17H3.25A2.25 2.25 0 0 1 1 14.75v-9.5Zm1.5 5.81v3.69c0 .414.336.75.75.75h13.5a.75.75 0 0 0 .75-.75v-2.69l-2.22-2.219a.75.75 0 0 0-1.06 0l-1.91 1.909.47.47a.75.75 0 1 1-1.06 1.06L6.53 8.091a.75.75 0 0 0-1.06 0l-2.97 2.97ZM12 7a1 1 0 1 1-2 0 1 1 0 0 1 2 0Z\" clip-rule=\"evenodd\" />\n </svg>\n {{ end }}\n </div>\n\n <div style=\"flex-grow:1; min-width:0;\">\n <a class=\"size-h4 block text-truncate color-highlight\">\n {{ .JSON.String \"host\" }}\n {{ if .JSON.Bool \"online\" }}\n <span\n style=\"width: 8px; height: 8px; border-radius: 50%; background-color: var(--color-positive); display: inline-block; vertical-align: middle;\"\n data-popover-type=\"text\"\n data-popover-text=\"Online\"\n ></span>\n {{ else }}\n <span\n style=\"width: 8px; height: 8px; border-radius: 50%; background-color: var(--color-negative); display: inline-block; vertical-align: middle;\"\n data-popover-type=\"text\"\n data-popover-text=\"Offline\"\n ></span>\n {{ end }}\n </a>\n\n <ul class=\"list-horizontal-text\">\n <li>\n {{ if .JSON.Bool \"online\" }}\n <span>{{ .JSON.String \"version.name_clean\" }}</span>\n {{ else }}\n <span>Offline</span>\n {{ end }}\n </li>\n {{ if .JSON.Bool \"online\" }}\n <li data-popover-type=\"html\">\n <div data-popover-html>\n {{ range .JSON.Array \"players.list\" }}{{ .String \"name_clean\" }}<br>{{ end }}\n </div>\n <p style=\"display:inline-flex;align-items:center;\">\n <svg xmlns=\"http://www.w3.org/2000/svg\" viewBox=\"0 0 24 24\" fill=\"currentColor\" class=\"size-6\" style=\"height:1em;vertical-align:middle;margin-right:0.5em;\">\n <path fill-rule=\"evenodd\" d=\"M7.5 6a4.5 4.5 0 1 1 9 0 4.5 4.5 0 0 1-9 0ZM3.751 20.105a8.25 8.25 0 0 1 16.498 0 .75.75 0 0 1-.437.695A18.683 18.683 0 0 1 12 22.5c-2.786 0-5.433-.608-7.812-1.7a.75.75 0 0 1-.437-.695Z\" clip-rule=\"evenodd\" />\n </svg>\n {{ .JSON.Int \"players.online\" | formatNumber }}/{{ .JSON.Int \"players.max\" | formatNumber }} players\n </p>\n </li>\n {{ else }}\n <li>\n <p style=\"display:inline-flex;align-items:center;\">\n <svg xmlns=\"http://www.w3.org/2000/svg\" viewBox=\"0 0 24 24\" fill=\"currentColor\" class=\"size-6\" style=\"height:1em;vertical-align:middle;margin-right:0.5em;opacity:0.5;\">\n <path fill-rule=\"evenodd\" d=\"M7.5 6a4.5 4.5 0 1 1 9 0 4.5 4.5 0 0 1-9 0ZM3.751 20.105a8.25 8.25 0 0 1 16.498 0 .75.75 0 0 1-.437.695A18.683 18.683 0 0 1 12 22.5c-2.786 0-5.433-.608-7.812-1.7a.75.75 0 0 1-.437-.695Z\" clip-rule=\"evenodd\" />\n </svg>\n 0 players\n </p>\n </li>\n {{ end }}\n </ul>\n </div>\n</div>"; # template = "<div style=\"display:flex; align-items:center; gap:12px;\">\n <div style=\"width:40px; height:40px; flex-shrink:0; border-radius:4px; display:flex; justify-content:center; align-items:center; overflow:hidden;\">\n {{ if .JSON.Bool \"online\" }}\n <img src=\"{{ .JSON.String \"icon\" | safeURL }}\" width=\"64\" height=\"64\" style=\"object-fit:contain;\">\n {{ else }}\n <svg xmlns=\"http://www.w3.org/2000/svg\" viewBox=\"0 0 20 20\" fill=\"currentColor\" style=\"width:32px; height:32px; opacity:0.5;\">\n <path fill-rule=\"evenodd\" d=\"M1 5.25A2.25 2.25 0 0 1 3.25 3h13.5A2.25 2.25 0 0 1 19 5.25v9.5A2.25 2.25 0 0 1 16.75 17H3.25A2.25 2.25 0 0 1 1 14.75v-9.5Zm1.5 5.81v3.69c0 .414.336.75.75.75h13.5a.75.75 0 0 0 .75-.75v-2.69l-2.22-2.219a.75.75 0 0 0-1.06 0l-1.91 1.909.47.47a.75.75 0 1 1-1.06 1.06L6.53 8.091a.75.75 0 0 0-1.06 0l-2.97 2.97ZM12 7a1 1 0 1 1-2 0 1 1 0 0 1 2 0Z\" clip-rule=\"evenodd\" />\n </svg>\n {{ end }}\n </div>\n\n <div style=\"flex-grow:1; min-width:0;\">\n <a class=\"size-h4 block text-truncate color-highlight\">\n {{ .JSON.String \"host\" }}\n {{ if .JSON.Bool \"online\" }}\n <span\n style=\"width: 8px; height: 8px; border-radius: 50%; background-color: var(--color-positive); display: inline-block; vertical-align: middle;\"\n data-popover-type=\"text\"\n data-popover-text=\"Online\"\n ></span>\n {{ else }}\n <span\n style=\"width: 8px; height: 8px; border-radius: 50%; background-color: var(--color-negative); display: inline-block; vertical-align: middle;\"\n data-popover-type=\"text\"\n data-popover-text=\"Offline\"\n ></span>\n {{ end }}\n </a>\n\n <ul class=\"list-horizontal-text\">\n <li>\n {{ if .JSON.Bool \"online\" }}\n <span>{{ .JSON.String \"version.name_clean\" }}</span>\n {{ else }}\n <span>Offline</span>\n {{ end }}\n </li>\n {{ if .JSON.Bool \"online\" }}\n <li data-popover-type=\"html\">\n <div data-popover-html>\n {{ range .JSON.Array \"players.list\" }}{{ .String \"name_clean\" }}<br>{{ end }}\n </div>\n <p style=\"display:inline-flex;align-items:center;\">\n <svg xmlns=\"http://www.w3.org/2000/svg\" viewBox=\"0 0 24 24\" fill=\"currentColor\" class=\"size-6\" style=\"height:1em;vertical-align:middle;margin-right:0.5em;\">\n <path fill-rule=\"evenodd\" d=\"M7.5 6a4.5 4.5 0 1 1 9 0 4.5 4.5 0 0 1-9 0ZM3.751 20.105a8.25 8.25 0 0 1 16.498 0 .75.75 0 0 1-.437.695A18.683 18.683 0 0 1 12 22.5c-2.786 0-5.433-.608-7.812-1.7a.75.75 0 0 1-.437-.695Z\" clip-rule=\"evenodd\" />\n </svg>\n {{ .JSON.Int \"players.online\" | formatNumber }}/{{ .JSON.Int \"players.max\" | formatNumber }} players\n </p>\n </li>\n {{ else }}\n <li>\n <p style=\"display:inline-flex;align-items:center;\">\n <svg xmlns=\"http://www.w3.org/2000/svg\" viewBox=\"0 0 24 24\" fill=\"currentColor\" class=\"size-6\" style=\"height:1em;vertical-align:middle;margin-right:0.5em;opacity:0.5;\">\n <path fill-rule=\"evenodd\" d=\"M7.5 6a4.5 4.5 0 1 1 9 0 4.5 4.5 0 0 1-9 0ZM3.751 20.105a8.25 8.25 0 0 1 16.498 0 .75.75 0 0 1-.437.695A18.683 18.683 0 0 1 12 22.5c-2.786 0-5.433-.608-7.812-1.7a.75.75 0 0 1-.437-.695Z\" clip-rule=\"evenodd\" />\n </svg>\n 0 players\n </p>\n </li>\n {{ end }}\n </ul>\n </div>\n</div>";
} # }
]; ];
} }
{ {
@@ -335,16 +346,84 @@ in {
}; };
}; };
# add to udr to glance # add to vaniville services to glance
homelab.glance.links.services = [
{
title = "vaultwarden";
url = "https://pass.${homelab.public_domain}";
error-url = "https://pass.vaniville.${homelab.public_domain}";
check-url = "https://pass.${homelab.public_domain}";
icon = "di:vaultwarden";
}
{
title = "gitea";
url = "https://git.${homelab.public_domain}";
error-url = "https://git.vaniville.${homelab.public_domain}";
check-url = "https://git.${homelab.public_domain}";
icon = "di:gitea";
}
];
homelab.glance.links.system = [ homelab.glance.links.system = [
{ {
title = "bebe"; title = "vaniville uptime";
url = "https://bebe.holocron.blue"; url = "https://up.${homelab.public_domain}";
error-url = "https://10.10.0.1"; error-url = "https://up.vaniville.${homelab.public_domain}";
check-url = "https://10.10.0.1"; check-url = "https://up.${homelab.public_domain}";
icon = "di:uptime-kuma";
}
];
# add to udr to glance
homelab.glance.links.network = [
{
title = "shauna";
url = "https://shauna.holocron.blue";
error-url = "https://10.0.0.1";
check-url = "https://10.0.0.1";
icon = "di:unifi"; icon = "di:unifi";
allow-insecure = true; allow-insecure = true;
} }
{
title = "lifeboat";
url = "https://lifeboat.holocron.blue";
error-url = "https://100.101.11.5";
check-url = "https://100.101.11.5";
icon = "di:unifi";
allow-insecure = true;
}
{
title = "korrina";
url = "https://korrina.holocron.blue";
error-url = "https://100.101.11.1";
check-url = "https://100.101.11.1";
icon = "di:unifi";
allow-insecure = true;
}
{
title = "linode";
url = "https://cloud.linode.com/linodes";
error-url = "https://status.linode.com";
check-url = "https://cloud.linode.com/linodes";
icon = "di:linode";
allow-insecure = true;
}
{
title = "tailscale";
url = "https://console.tailscale.com/admin/machines";
error-url = "https://status.tailscale.com/";
check-url = "https://console.tailscale.com/admin/machines";
icon = "di:tailscale";
allow-insecure = true;
}
{
title = "nextdns";
url = "https://my.nextdns.io";
error-url = "https://test.nextdns.io";
check-url = "https://my.nextdns.io/527db2/setup";
icon = "di:nextdns";
allow-insecure = true;
}
]; ];
}; };
} }
@@ -87,8 +87,8 @@ in {
}; };
# open firewall # open firewall
networking.firewall.allowedTCPPorts = [cfg.port 8123 21063]; networking.firewall.allowedTCPPorts = [cfg.port 8123 21063 21064];
networking.firewall.allowedUDPPorts = [21063]; networking.firewall.allowedUDPPorts = [5353];
# add to caddy for reverse proxy # add to caddy for reverse proxy
services.caddy.virtualHosts."${cfg.url}" = { services.caddy.virtualHosts."${cfg.url}" = {
@@ -85,6 +85,7 @@ in {
}; };
homeassistant = { homeassistant = {
enabled = true; enabled = true;
experimental_event_entities = true;
}; };
}; };
}; };
@@ -2,23 +2,20 @@
pkgs, pkgs,
config, config,
lib, lib,
inputs,
... ...
}: let }: let
service = "copyparty"; service = "homebox";
cfg = config.holocron.${service}; cfg = config.homelab.${service};
sec = config.sops.secrets; sec = config.sops.secrets;
homelab = config.homelab; homelab = config.homelab;
in { in {
imports = [inputs.copyparty.nixosModules.default]; options.homelab.${service} = {
options.holocron.${service} = {
enable = lib.mkEnableOption "enables ${service}"; enable = lib.mkEnableOption "enables ${service}";
# set port options # set port options
port = lib.mkOption { port = lib.mkOption {
type = lib.types.int; type = lib.types.int;
default = 7902; default = 7709;
description = "set port for ${service} (default: ${toString cfg.port}"; description = "set port for ${service} (default: ${toString cfg.port}";
}; };
url = lib.mkOption { url = lib.mkOption {
@@ -41,10 +38,13 @@ in {
default = true; default = true;
description = "enable backups for ${service}"; description = "enable backups for ${service}";
}; };
motd = lib.mkOption {
type = lib.types.nullOr lib.types.str;
default = service;
};
}; };
config = lib.mkIf cfg.enable { config = lib.mkIf cfg.enable {
nixpkgs.overlays = [inputs.copyparty.overlays.default];
# declare ${service} group # declare ${service} group
users.groups.${service} = { users.groups.${service} = {
gid = lib.mkForce cfg.ids; gid = lib.mkForce cfg.ids;
@@ -58,7 +58,6 @@ in {
home = cfg.data_dir; home = cfg.data_dir;
createHome = true; createHome = true;
group = service; group = service;
extraGroups = [ "media" "blake" "archives" ];
}; };
# enable the ${service} service # enable the ${service} service
@@ -67,56 +66,24 @@ in {
user = service; user = service;
group = service; group = service;
settings = { settings = {
i = "0.0.0.0"; HBOX_WEB_PORT = toString cfg.port;
p = [7902]; HBOX_STORAGE_CONN_STRING = "file://${cfg.data_dir}";
rproxy = 1; HBOX_STORAGE_PREFIX_PATH = "data";
}; HBOX_DATABASE_DRIVER = "sqlite3";
accounts = { HBOX_DATABASE_SQLITE_PATH = "${cfg.data_dir}/data/homebox.db?_pragma=busy_timeout=999&_pragma=journal_mode=WAL&_fk=1";
blake = { HBOX_OPTIONS_ALLOW_REGISTRATION = "false";
passwordFile = sec."copyparty_passwd".path; HBOX_OPTIONS_GITHUB_RELEASE_CHECK = "false";
}; HBOX_MODE = "production";
}; HOME = cfg.data_dir;
groups = { TMPDIR = "${cfg.data_dir}/tmp";
media = ["blake"];
};
volumes = {
"/archives" = {
path = "/holocron/archives";
access = {
r = "*";
A = "blake";
};
flags = {
chmod_f = 660;
chmod_d = 770;
#gid = ?;
};
};
"/media" = {
path = "/holocron/media";
access = {
r = "*";
w = "@media";
A = "blake";
};
flags = {
chmod_f = 660;
chmod_d = 770;
gid = "700";
};
};
"/users/blake" = {
path = "/holocron/users/blake";
access = {
A = "blake";
};
flags = {
chmod_f = 660;
chmod_d = 770;
gid = "1000";
};
}; };
}; };
# override umask to make permissions work out
systemd.services.${service}.serviceConfig = {
UMask = lib.mkForce "0007";
User = service;
Group = service;
}; };
# open firewall # open firewall
@@ -124,16 +91,14 @@ in {
# add to caddy for reverse proxy # add to caddy for reverse proxy
services.caddy.virtualHosts."${cfg.url}" = { services.caddy.virtualHosts."${cfg.url}" = {
serverAliases = ["${service}.${homelab.public_domain}"];
extraConfig = '' extraConfig = ''
tls /etc/ssl/blakedheld.xyz.crt /etc/ssl/blakedheld.xyz.key tls internal
reverse_proxy 127.0.0.1:${toString cfg.port} { reverse_proxy 127.0.0.1:${toString cfg.port}
}
''; '';
}; };
# add to glance (local service) # add to glance (local service)
homelab.glance.links.system = [ homelab.glance.links.services = [
{ {
title = service; title = service;
url = "https://${cfg.url}"; url = "https://${cfg.url}";
@@ -142,13 +107,14 @@ in {
icon = "di:${service}"; icon = "di:${service}";
} }
]; ];
#---------------------------------------------------------------------------
sops.secrets = { #
"${service}_passwd" = { # sops.secrets = {
owner = service; # "${service}_" = {
group = service; # owner = ;
}; # group = ;
}; # };
# };
# add to backups # add to backups
homelab.backups.baks = { homelab.backups.baks = {
@@ -65,12 +65,13 @@ in {
enable = true; enable = true;
package = pkgs.unstable.vaultwarden; package = pkgs.unstable.vaultwarden;
config = { config = {
DOMAIN = domain; DOMAIN = "pass.${homelab.public_domain}";
IP_HEADER = "X-Forwarded-For";
ROCKET_ADDRESS = "0.0.0.0"; ROCKET_ADDRESS = "0.0.0.0";
ROCKET_PORT = cfg.port; ROCKET_PORT = cfg.port;
SIGNUPS_ALLOWED = true; SIGNUPS_ALLOWED = true;
ADMIN_TOKEN = "${toString sec."vaultwarden_admin_token".path}"; ADMIN_TOKEN = "$argon2id$v=19$m=19456,t=2,p=1$YXJKa0ZubE9OZkp5c0NlMC95TFhBcFh3K1VsUkk1bElTSFJkbmdYdmp4az0$bsLT8/18BmexUbzqlHp0S4aoIxi6bYxl0IY0EweF5N4";
EXPERIMENTAL_CLIENT_FEATURE_FLAGS = "fido2-vault-credentials,autofill-overlay,autofill-v2,inline-menu-positioning-improvements,ssh-key-vault-item"; EXPERIMENTAL_CLIENT_FEATURE_FLAGS = "ssh-key-vault-item";
}; };
}; };
@@ -83,8 +84,8 @@ in {
# add to caddy for reverse proxy # add to caddy for reverse proxy
services.caddy.virtualHosts."${cfg.url}" = { services.caddy.virtualHosts."${cfg.url}" = {
serverAliases = ["pass.${homelab.public_domain}"]; serverAliases = ["pass.${homelab.public_domain}"];
#tls internal
extraConfig = '' extraConfig = ''
tls internal
reverse_proxy 127.0.0.1:${toString cfg.port} reverse_proxy 127.0.0.1:${toString cfg.port}
''; '';
}; };
+125
View File
@@ -0,0 +1,125 @@
{
pkgs,
config,
lib,
inputs,
...
}: let
nixservice = "wger";
service = "wger";
cfg = config.homelab.${service};
sec = config.sops.secrets;
homelab = config.homelab;
in {
options.homelab.${service} = {
enable = lib.mkEnableOption "enables ${service}";
# set port options
port = lib.mkOption {
type = lib.types.int;
default = 7707;
description = "set port for ${service} (default: ${toString cfg.port}";
};
url = lib.mkOption {
type = lib.types.str;
default = "${service}.${homelab.base_domain}";
description = "set domain for ${service}";
};
data_dir = lib.mkOption {
type = lib.types.str;
default = "/var/lib/${service}";
description = "set data directory for ${service}";
};
ids = lib.mkOption {
type = lib.types.int;
default = cfg.port;
description = "set uid and pid of ${service} user (matches port by default)";
};
backup = lib.mkOption {
type = lib.types.bool;
default = true;
description = "enable backups for ${service}";
};
motd = lib.mkOption {
type = lib.types.nullOr lib.types.str;
default = "podman-wger";
};
};
config = lib.mkIf cfg.enable {
# declare ${service} group
users.groups.${service} = {gid = lib.mkForce cfg.ids;};
# declare ${service} user
users.users.${service} = {
description = "${service} server user";
uid = lib.mkForce cfg.ids;
isSystemUser = true;
home = cfg.data_dir;
createHome = true;
group = service;
extraGroups = [];
};
# still suss as fuck bro man fuck
virtualisation.oci-containers.containers = {
hass = {
image = "homeassistant/home-assistant:stable";
autoStart = true;
extraOptions = [
"--pull=newer"
"--network=host"
];
volumes = [
"${cfg.data_dir}:/config"
];
environment = {
TZ = homelab.tz;
PUID = toString config.users.users.${service}.uid;
PGID = toString config.users.groups.${service}.gid;
};
};
};
# override umask to make permissions work out
systemd.services.${service}.serviceConfig = {
UMask = lib.mkForce "0007";
};
# open firewall
networking.firewall.allowedTCPPorts = [cfg.port 8123 21063 21064];
networking.firewall.allowedUDPPorts = [5353];
# add to caddy for reverse proxy
services.caddy.virtualHosts."${cfg.url}" = {
serverAliases = ["${service}.${homelab.public_domain}"];
extraConfig = ''
tls internal
reverse_proxy 127.0.0.1:${toString cfg.port} {
header_up Host {host}
header_up X-Real-IP {remote_host}
header_up X-Forwarded-For {remote_host}
header_up X-Forwarded-Proto https
}
'';
};
# add to glance
homelab.glance.links.services = [
{
title = "wger";
url = "https://hass.${homelab.public_domain}";
error-url = "http://${homelab.host_ip}:${toString cfg.port}";
check-url = "http://${homelab.host_ip}:${toString cfg.port}";
icon = "di:${nixservice}";
}
];
# add to backups
homelab.backups.baks = {
${service} = {paths = [cfg.data_dir];};
};
};
}
+28 -3
View File
@@ -18,6 +18,7 @@ zstd -dc <path_to_backup> | sudo -u postgres psql -d <database_name> # restore
let let
cfg = config.homelab.backups; cfg = config.homelab.backups;
sec = config.sops.secrets; sec = config.sops.secrets;
host = config.networking.hostName;
in { in {
options.homelab.backups = { options.homelab.backups = {
enable = lib.mkEnableOption "enables borg backups for state files and db backup services"; enable = lib.mkEnableOption "enables borg backups for state files and db backup services";
@@ -26,11 +27,26 @@ in {
default = {}; default = {};
description = "backup jobs, nested attribute sets should be <bak_name> = paths [<list_of_paths>]"; description = "backup jobs, nested attribute sets should be <bak_name> = paths [<list_of_paths>]";
}; };
databases = lib.mkOption {
type = lib.types.bool;
default = true;
description = "if databases are present, runs dumps";
};
backup_repo = lib.mkOption { backup_repo = lib.mkOption {
type = lib.types.path; type = lib.types.path;
default = "/holocron/archives/homelab"; default = "/holocron/archives/servers/${host}/homelab";
description = "path to take daily backups to with borg!"; description = "path to take daily backups to with borg!";
}; };
offsite = lib.mkOption {
type = lib.types.bool;
default = true;
description = "bool to control weather or not the repo is backed up offsite";
};
homelab = lib.mkOption {
type = lib.types.bool;
default = false;
description = "bool to control weather or not the repo is backed up to homelab";
};
offsite_user = lib.mkOption { offsite_user = lib.mkOption {
type = lib.types.str; type = lib.types.str;
default = "lifeboat"; default = "lifeboat";
@@ -59,17 +75,26 @@ in {
group = "archives"; group = "archives";
encryption.mode = "repokey-blake2"; encryption.mode = "repokey-blake2";
encryption.passCommand = "cat ${sec."borg_passwd".path}"; encryption.passCommand = "cat ${sec."borg_passwd".path}";
preHook = '' preHook = lib.mkIf cfg.databases ''
systemctl start mysql-backup.service systemctl start mysql-backup.service
systemctl start $(systemctl list-unit-files 'postgresqlBackup-*.service' --no-legend --no-pager | cut -d' ' -f1) systemctl start $(systemctl list-unit-files 'postgresqlBackup-*.service' --no-legend --no-pager | cut -d' ' -f1)
''; '';
postHook = '' postHook = lib.mkIf (cfg.offsite || cfg.homelab) ''
${lib.optionalString cfg.offsite ''
${pkgs.sshpass}/bin/sshpass -f ${sec."lifeboat_rsync".path} \ ${pkgs.sshpass}/bin/sshpass -f ${sec."lifeboat_rsync".path} \
${pkgs.rsync}/bin/rsync -aHAX --partial --numeric-ids --info=progress2,name1,stats2 --delete \ ${pkgs.rsync}/bin/rsync -aHAX --partial --numeric-ids --info=progress2,name1,stats2 --delete \
-e "ssh -o StrictHostKeyChecking=no" \ -e "ssh -o StrictHostKeyChecking=no" \
${toString cfg.backup_repo} \ ${toString cfg.backup_repo} \
${cfg.offsite_user}@${cfg.offsite_target}::${cfg.offsite_dir} ${cfg.offsite_user}@${cfg.offsite_target}::${cfg.offsite_dir}
''}
${lib.optionalString cfg.homelab ''
${pkgs.rsync}/bin/rsync -aHAX --partial --numeric-ids --info=progress2,name1,stats2 --delete \
-e "ssh -i /home/blake/.ssh/id_vaniville -o StrictHostKeyChecking=no" \
${toString cfg.backup_repo} \
blake@lumiose:/holocron/archives/servers/vaniville
''}
''; '';
extraArgs = ["--verbose" "--show-rc" "--umask" "0007"]; extraArgs = ["--verbose" "--show-rc" "--umask" "0007"];
extraCreateArgs = ["--list" "--stats" "--filter" "AME"]; extraCreateArgs = ["--list" "--stats" "--filter" "AME"];
prune.keep = { prune.keep = {
@@ -75,9 +75,8 @@ in {
# add to caddy for reverse proxy # add to caddy for reverse proxy
services.caddy.virtualHosts."${cfg.url}" = { services.caddy.virtualHosts."${cfg.url}" = {
serverAliases = ["up.${homelab.public_domain}"]; #serverAliases = ["up.${homelab.public_domain}"];
extraConfig = '' extraConfig = ''
tls internal
reverse_proxy 127.0.0.1:${toString cfg.port} reverse_proxy 127.0.0.1:${toString cfg.port}
''; '';
}; };
+1 -1
View File
@@ -16,7 +16,7 @@ in {
}; };
interval = lib.mkOption { interval = lib.mkOption {
type = lib.types.str; type = lib.types.str;
default = "60s"; default = "45s";
}; };
}; };
+8 -6
View File
@@ -1,9 +1,11 @@
{ pkgs, config, lib, ... }:
let
cfg = config.system.ssh;
in
{ {
pkgs,
config,
lib,
...
}: let
cfg = config.system.ssh;
in {
options.system.ssh = { options.system.ssh = {
enable = lib.mkEnableOption "enables ssh"; enable = lib.mkEnableOption "enables ssh";
}; };
@@ -14,7 +16,7 @@ in
enable = true; enable = true;
settings = { settings = {
PasswordAuthentication = false; PasswordAuthentication = false;
PermitRootLogin = "no"; PermitRootLogin = "prohibit-password";
X11Forwarding = false; X11Forwarding = false;
}; };
}; };
+1 -1
View File
@@ -37,7 +37,7 @@ in {
"mew" = {id = "7ZC2NAS-QONQKAL-Z54NPMB-7TRXM6M-K7Z6PZD-FG4AI4H-V7SMFJN-JOYBHQO";}; "mew" = {id = "7ZC2NAS-QONQKAL-Z54NPMB-7TRXM6M-K7Z6PZD-FG4AI4H-V7SMFJN-JOYBHQO";};
"yveltal" = {id = "ZVSQ4WJ-7OICYOZ-3ECES4X-KH37IPB-TKHKUJG-BSEGXVM-AHYY5C3-VKG44AX";}; "yveltal" = {id = "ZVSQ4WJ-7OICYOZ-3ECES4X-KH37IPB-TKHKUJG-BSEGXVM-AHYY5C3-VKG44AX";};
"CEN-IT-07" = {id = "DPYKA4Z-3PX7JB2-FBEOXXX-SC7TLT2-QC5P2IR-SXOPJGX-QO3DMII-5B7UCA4";}; "CEN-IT-07" = {id = "DPYKA4Z-3PX7JB2-FBEOXXX-SC7TLT2-QC5P2IR-SXOPJGX-QO3DMII-5B7UCA4";};
"CEN-IT-00007" = {id = "XBPXGYU-DUJSLDH-6BDNF4D-CO2COC3-N3FM6W5-IHZOJBM-Z2N77RI-IVAV5AH";}; "CEN-IT-00007" = {id = "UEWNSUZ-AX75M5Y-OA4FURY-ORMEXFA-XUXU4LU-LEUYKVW-IDM2GQC-4UR4YAL";};
}; };
folders = { folders = {
"holocron" = { "holocron" = {
+5 -4
View File
@@ -11,6 +11,7 @@ lifeboat_rsync: ENC[AES256_GCM,data:OaijbFFpu8RM3gcWu2XbAHeuUhTIjFNO8aYcA8TJmNxM
#ENC[AES256_GCM,data:NbXyRroLF2uxHjROnBg9OLQ=,iv:W9Nse9yamov3rflDKBeISO+miQkjH7QfBUZdsDmDM4I=,tag:/RmH3JyriXFxf0hEh9/iRQ==,type:comment] #ENC[AES256_GCM,data:NbXyRroLF2uxHjROnBg9OLQ=,iv:W9Nse9yamov3rflDKBeISO+miQkjH7QfBUZdsDmDM4I=,tag:/RmH3JyriXFxf0hEh9/iRQ==,type:comment]
cloudflare: cloudflare:
api_token: ENC[AES256_GCM,data:VuRwfZe1cdnQLvxlp9GCDOt9Ijhz4fh2yOev2wLOdLV+zw91blA3Zis2BRyI/ZwN4y+IhiqlpBzXCsoFqw==,iv:6Bt11zz1/slvszh9ZGQ0ov5ts0jAZIAMx3G2AimKIs4=,tag:tyEVhsKCGrJWm6yn+GUlUQ==,type:str] api_token: ENC[AES256_GCM,data:VuRwfZe1cdnQLvxlp9GCDOt9Ijhz4fh2yOev2wLOdLV+zw91blA3Zis2BRyI/ZwN4y+IhiqlpBzXCsoFqw==,iv:6Bt11zz1/slvszh9ZGQ0ov5ts0jAZIAMx3G2AimKIs4=,tag:tyEVhsKCGrJWm6yn+GUlUQ==,type:str]
api_token_caddy: ENC[AES256_GCM,data:L1PMeI4zOCPbWuWrczM1aSYl/qk/MW8xLtxr/PL+a3zfDA+USP8Yw4liYnn1qwTxs+oLMHhpBR58kHPr8Q==,iv:NNVBPANwQ9koAKTQD4ikhtwFjCpMLMXEm9scj9jIDFo=,tag:SXt1Y+04BuSsjDhu5ykwLA==,type:str]
#ENC[AES256_GCM,data:3Nnp9ASh+BPPwSOa+Xx3YEqKnh48oW6sWCQCXy9iZ61qGv9Ubjeaccr+Bh0bD9s=,iv:LwbptKdbhO2yki2BIK+6uPMqe14FNC4EcIwO6HS5xAc=,tag:38P0kwfAFVEps6MnMU8XeA==,type:comment] #ENC[AES256_GCM,data:3Nnp9ASh+BPPwSOa+Xx3YEqKnh48oW6sWCQCXy9iZ61qGv9Ubjeaccr+Bh0bD9s=,iv:LwbptKdbhO2yki2BIK+6uPMqe14FNC4EcIwO6HS5xAc=,tag:38P0kwfAFVEps6MnMU8XeA==,type:comment]
email_pass: ENC[AES256_GCM,data:T4heTFuvD3rUJUInDpJnIhwECw==,iv:uDOk6FKtfYjedE/I3zh9Tl7QuYz/OBe/3tlrTitf2DY=,tag:a80RoPPHMSETAbk5pqGfiQ==,type:str] email_pass: ENC[AES256_GCM,data:T4heTFuvD3rUJUInDpJnIhwECw==,iv:uDOk6FKtfYjedE/I3zh9Tl7QuYz/OBe/3tlrTitf2DY=,tag:a80RoPPHMSETAbk5pqGfiQ==,type:str]
#ENC[AES256_GCM,data:ztRwuY0mTMDmwV5HqVR7Dmc+dCWcrVRtWZGEL1abE/WUcA==,iv:mmaWfHRiENJUGNhyUBFo1z7PdzVPH1OUZrVhkce6KV0=,tag:GKEvT0qkzTtimQXDueKPdw==,type:comment] #ENC[AES256_GCM,data:ztRwuY0mTMDmwV5HqVR7Dmc+dCWcrVRtWZGEL1abE/WUcA==,iv:mmaWfHRiENJUGNhyUBFo1z7PdzVPH1OUZrVhkce6KV0=,tag:GKEvT0qkzTtimQXDueKPdw==,type:comment]
@@ -36,7 +37,7 @@ cs2:
#ENC[AES256_GCM,data:mbIgMJBhL8nWJzl8q2dFL8XtO1Xa1Q==,iv:caYHYp1boK9wRgCcQe40HTWT/HxAIvYe+HyaruI53Vc=,tag:S6wowhAHObEcs7z8FimZ1g==,type:comment] #ENC[AES256_GCM,data:mbIgMJBhL8nWJzl8q2dFL8XtO1Xa1Q==,iv:caYHYp1boK9wRgCcQe40HTWT/HxAIvYe+HyaruI53Vc=,tag:S6wowhAHObEcs7z8FimZ1g==,type:comment]
wg_mex_key: ENC[AES256_GCM,data:vxDXixo6X6D33+p21L4hB0/yCH+TvMHZl991BkRsE/jdz7rzZuJF+zI7h+Q=,iv:8WR+feHXNUcat8DB2wY7wpos+P7TzgRF7rFD0fYosjY=,tag:p9b9ck0/VZjyLxtHut3n5Q==,type:str] wg_mex_key: ENC[AES256_GCM,data:vxDXixo6X6D33+p21L4hB0/yCH+TvMHZl991BkRsE/jdz7rzZuJF+zI7h+Q=,iv:8WR+feHXNUcat8DB2wY7wpos+P7TzgRF7rFD0fYosjY=,tag:p9b9ck0/VZjyLxtHut3n5Q==,type:str]
#ENC[AES256_GCM,data:CO5nrcDbgymnEmCvuTexOBEMncuNM5lQ,iv:6HrxqSN6e7ODuz09MIFgPbIqDCKQySRDaKk5Wdu4HoQ=,tag:JBRjZeEdOg+trohfanO6Mg==,type:comment] #ENC[AES256_GCM,data:CO5nrcDbgymnEmCvuTexOBEMncuNM5lQ,iv:6HrxqSN6e7ODuz09MIFgPbIqDCKQySRDaKk5Wdu4HoQ=,tag:JBRjZeEdOg+trohfanO6Mg==,type:comment]
vaultwarden_admin_token: ENC[AES256_GCM,data:G1v3N064ci0Fw5EtTzaryailWpsv6f4w6eoHp2vjXIBtIlScdQk1Q0W+eDNRk8Wr2C3ysTXQNbyYismNsls+jeS3W+YqkKL4fnh3a5UTzQrMqvaH11n3ak0X9R9vmt+ZJXBrUrAOKJ6RPHJJSWenhjDB77kwEdQ=,iv:f8X+x/AdmZ3b3dtcSFrxGgA2tCgDRpgddjlVu3mdCmM=,tag:c0MXljVvhwOdvrb/8hWlsQ==,type:str] vaultwarden_admin_token: ENC[AES256_GCM,data:Ow5UcBXe+36POaR099v4Sl0ObLu6/lmk4OO5F3sA6BxoSD3e0LFdlvn2QyWKAUOeBSF9ZoLLSnZwc8xd2vt4xm8WQXe7OupO4yAGeE2P0vNcyMTKXxS48scibDvdoGYEtbfbH3JH29pOF7l6LetWcX3T121mPrNz8bHknj3UXHLYdYm8+eA=,iv:iFZYixNJCpK/VB3AasFO/XdPKL4wh5B9HzSKU39LRn0=,tag:m4wC0CpZK4N6rlKoEa5OZw==,type:str]
#ENC[AES256_GCM,data:2ESzSsQZqKdjD7OXN8ZPThj6g9acJREe,iv:aDFPB0vs8NNo8ExLcJw7qtQvWbCb1XK6TJrHSK86qss=,tag:z+dypHAGUjEXP7Y9MHYWwg==,type:comment] #ENC[AES256_GCM,data:2ESzSsQZqKdjD7OXN8ZPThj6g9acJREe,iv:aDFPB0vs8NNo8ExLcJw7qtQvWbCb1XK6TJrHSK86qss=,tag:z+dypHAGUjEXP7Y9MHYWwg==,type:comment]
gitea_database_password: ENC[AES256_GCM,data:nhFn0/G7gW5rk996OZzlcTt7T9KMbP8MNM+ReFC8w1H9ZqBSJUbs3K+n68uQVrkOVSXE0cKpOR1VbQ+i+46z3g==,iv:bT4GRZZ83v47/EmeV2KaUFo+4qTT4T2AktFUpPiZdF4=,tag:OC9TInkAr1egM+xnBDizxw==,type:str] gitea_database_password: ENC[AES256_GCM,data:nhFn0/G7gW5rk996OZzlcTt7T9KMbP8MNM+ReFC8w1H9ZqBSJUbs3K+n68uQVrkOVSXE0cKpOR1VbQ+i+46z3g==,iv:bT4GRZZ83v47/EmeV2KaUFo+4qTT4T2AktFUpPiZdF4=,tag:OC9TInkAr1egM+xnBDizxw==,type:str]
#ENC[AES256_GCM,data:HJ81OxRD2xtNZKv+8oDqiT8mYpv45JMvjxU5pdmEKzl64SK3lQ==,iv:wStoC6XaZlvRPfbqti2CUbPrOOTt4KktaUp2ecVrggU=,tag:isOwKfNdQZAM+E8YQXBSFA==,type:comment] #ENC[AES256_GCM,data:HJ81OxRD2xtNZKv+8oDqiT8mYpv45JMvjxU5pdmEKzl64SK3lQ==,iv:wStoC6XaZlvRPfbqti2CUbPrOOTt4KktaUp2ecVrggU=,tag:isOwKfNdQZAM+E8YQXBSFA==,type:comment]
@@ -83,7 +84,7 @@ sops:
PRu+itNolpPTHm96pe+P93g2iP0wgekG0cX21wkiU2xaLF3dY2FEIA== PRu+itNolpPTHm96pe+P93g2iP0wgekG0cX21wkiU2xaLF3dY2FEIA==
-----END AGE ENCRYPTED FILE----- -----END AGE ENCRYPTED FILE-----
recipient: age14gfh682a7m7jfp3qrulql03x5rs7yedwmxwksxrrmgjsunstyuksqx93pz recipient: age14gfh682a7m7jfp3qrulql03x5rs7yedwmxwksxrrmgjsunstyuksqx93pz
lastmodified: "2026-06-20T19:06:32Z" lastmodified: "2026-07-28T14:33:14Z"
mac: ENC[AES256_GCM,data:Z9QHyyB6GB8meEMlvVBsnKC/NBgDXH2oRc5Isbxi3Nf+zgiL+VL+i3CqHzRx6dFFVqct8zTu5CVNkQ9sbtGrhAccPUnE6sn/pLhsUBDEhvIdjsw5bHHRXZgNwJwNPd8Z4pUcDvQNzGvTDWW+ZkuvnmsdOdAvf5tjfVTGLve4mnU=,iv:E9XFqqThxTLMXKbah4iOkZLQex1bQEkuqrtrv0kKEKU=,tag:MpMkpT4fbaF35V0ZcYOpww==,type:str] mac: ENC[AES256_GCM,data:bEcpoMFzXbK4WCs94Y4I5CDo9JDC4/6iRMfgc41m1o8/qJhKyJUWWZcPhJSaRSituTYyPjSe8aB6k2Vwpgcd+hk41JC2Op09mnjBWfDQz6Ts0YbZAnZ/dV4IrzdxYRtM91EXmJnROeiTftGgYN/6Awa8I+ie3UFBl8u6/5UoD7o=,iv:MIhnNS9RGFWKJ0LI7Ae9gTEcGzfKwQB4bg4oSAs8/Go=,tag:W/zfVpxn+sRa+FOrR9fKyA==,type:str]
unencrypted_suffix: _unencrypted unencrypted_suffix: _unencrypted
version: 3.13.1 version: 3.13.2
+1
View File
@@ -27,6 +27,7 @@ in {
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIOVsjLEbnW/KeFXogppi0AP6ZbCZpObu7zFeRV/aLkP9 blake@lugia" "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIOVsjLEbnW/KeFXogppi0AP6ZbCZpObu7zFeRV/aLkP9 blake@lugia"
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIHJiskD81/2bd63sbJVSN0xPNwnbCGXheIBIKrwShDoo bhelderman@cen-it-07.local" "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIHJiskD81/2bd63sbJVSN0xPNwnbCGXheIBIKrwShDoo bhelderman@cen-it-07.local"
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIO06en1r4+zg8JMGPq7WiZeh/DBUvfhDJX3e+J5Z5Ttk blake@snowbelle" "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIO06en1r4+zg8JMGPq7WiZeh/DBUvfhDJX3e+J5Z5Ttk blake@snowbelle"
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIP0FLKK9yEPYpGuCjoX0e7Ky/zTPfzDk7IkrR3tOmELP blake@vaniville"
]; ];
}; };
}; };
+1 -1
View File
@@ -23,9 +23,9 @@ set ignorecase true
# shortcuts # shortcuts
map gb cd /holocron map gb cd /holocron
map gz cd %{{ [ -d /holocron ] && printf /holocron || printf /media/holocron }}
map gn cd ~/.nix map gn cd ~/.nix
map gc cd ~/.config map gc cd ~/.config
map gv cd /var/lib
# navigation # navigation
map [ half-up map [ half-up
+1 -1
View File
@@ -40,7 +40,7 @@ in {
user = "gitea"; user = "gitea";
port = 7567; port = 7567;
}; };
"bebe" = { "shauna" = {
hostname = "10.10.0.1"; hostname = "10.10.0.1";
user = "root"; user = "root";
}; };
+36 -8
View File
@@ -7,6 +7,7 @@
program = "zsh"; program = "zsh";
cfg = config.dots.${program}; cfg = config.dots.${program};
home_dir = config.home.homeDirectory; home_dir = config.home.homeDirectory;
isDarwin = pkgs.stdenv.isDarwin;
#sec = sops.secrets; #sec = sops.secrets;
in { in {
options.dots.${program} = { options.dots.${program} = {
@@ -23,7 +24,6 @@ in {
programs.${program} = { programs.${program} = {
enable = true; enable = true;
dotDir = "${config.xdg.configHome}/zsh"; dotDir = "${config.xdg.configHome}/zsh";
#dotDir = ".config/zsh";
autocd = true; autocd = true;
enableCompletion = true; enableCompletion = true;
@@ -41,18 +41,20 @@ in {
path = "$XDG_STATE_HOME/zsh/history"; path = "$XDG_STATE_HOME/zsh/history";
}; };
shellAliases = { shellAliases =
{
# --- zsh --- # --- zsh ---
cfz = "nvim ${home_dir}/.config/zsh/.zshrc";
src = "source ${home_dir}/.config/zsh/.zshrc"; src = "source ${home_dir}/.config/zsh/.zshrc";
# --- config editing --- # --- config editing ---
cfl = "nvim ${home_dir}/.config/lf/lfrc"; cfl = "nvim /home/blake/.nix/users/blake/dots/core/lf/lfrc";
cfz = "nvim /home/blake/.nix/users/blake/dots/core/zsh/default.nix";
cfv = "sudo lf /var/lib";
# --- navigation --- # --- navigation ---
ls = "ls --color=auto --group-directories-first"; # ls = "ls --color=auto --group-directories-first";
ll = "ls -lh --color=auto --group-directories-first"; # ll = "ls -lh --color=auto --group-directories-first";
la = "ls -Alh --color=auto --group-directories-first"; # la = "ls -Alh --color=auto --group-directories-first";
".." = "cd .."; ".." = "cd ..";
"..." = "cd ../.."; "..." = "cd ../..";
fs = "du -h | sort -h"; fs = "du -h | sort -h";
@@ -92,8 +94,19 @@ in {
pull = "git pull"; pull = "git pull";
dotfiles = "/usr/bin/git --git-dir=${home_dir}/.dotfiles --work-tree=$HOME"; dotfiles = "/usr/bin/git --git-dir=${home_dir}/.dotfiles --work-tree=$HOME";
dtf = "/usr/bin/git --git-dir=${home_dir}/.dotfiles --work-tree=$HOME"; dtf = "/usr/bin/git --git-dir=${home_dir}/.dotfiles --work-tree=$HOME";
# nix shit
sec = "sops ${home_dir}/.nix/secrets/secrets.yaml"; sec = "sops ${home_dir}/.nix/secrets/secrets.yaml";
# zfs
dfzfs = "zfs list -r -o name,used,usedsnap,usedds";
# --- yt-dlp ---
yt-music = "noglob yt-dlp -f 'bestaudio/best' --extract-audio --audio-format opus --audio-quality 0 --embed-metadata --embed-thumbnail -o '%(playlist_index)02d - %(title)s.%(ext)s'";
# --- dumb shit ---
fix-music = "sudo find /holocron/media/music -type d -exec chmod 2770 {} + && sudo find /holocron/media/music -type f -exec chmod 660 {} +";
# --- systemd --- # --- systemd ---
stat = "sudo systemctl status"; stat = "sudo systemctl status";
restart = "sudo systemctl restart"; restart = "sudo systemctl restart";
@@ -106,7 +119,21 @@ in {
peace = "systemctl poweroff"; peace = "systemctl poweroff";
love = "systemctl reboot"; love = "systemctl reboot";
lock = "loginctl lock-session"; lock = "loginctl lock-session";
}; }
# use GNU core utils ls on macos
// (
if isDarwin
then {
ls = "gls --color=auto --group-directories-first";
ll = "gls -lh --color=auto --group-directories-first";
la = "gls -Alh --color=auto --group-directories-first";
}
else {
ls = "ls --color=auto --group-directories-first";
ll = "ls -lh --color=auto --group-directories-first";
la = "ls -Alh --color=auto --group-directories-first";
}
);
initContent = '' initContent = ''
@@ -117,6 +144,7 @@ in {
alias lf='lfcd' alias lf='lfcd'
lfcd () {cd "$(command lf -print-last-dir "$@")"} lfcd () {cd "$(command lf -print-last-dir "$@")"}
''; '';
syntaxHighlighting = { syntaxHighlighting = {
+1
View File
@@ -10,6 +10,7 @@
./waybar ./waybar
./stylix ./stylix
./hypr ./hypr
./kde
./tofi ./tofi
./clipboard ./clipboard
./cursor ./cursor
+20
View File
@@ -0,0 +1,20 @@
{
pkgs,
lib,
config,
...
}: let
program = "plasma";
cfg = config.dots.${program};
#sec = sops.secrets;
in {
options.dots.${program} = {
enable = lib.mkEnableOption "enables ${program}";
};
config = lib.mkIf cfg.enable {
programs.${program} = {
enable = true;
};
};
}
+7 -1
View File
@@ -37,7 +37,7 @@ in {
identityFile = "${home_dir}/.ssh/id_snowbelle"; identityFile = "${home_dir}/.ssh/id_snowbelle";
port = 7567; port = 7567;
}; };
"bebe" = { "shauna" = {
hostname = "10.10.0.1"; hostname = "10.10.0.1";
user = "root"; user = "root";
identityFile = "${home_dir}/.ssh/id_snowbelle"; identityFile = "${home_dir}/.ssh/id_snowbelle";
@@ -49,8 +49,14 @@ in {
}; };
"vaniville" = { "vaniville" = {
hostname = "96.126.127.102"; hostname = "96.126.127.102";
identityFile = "${home_dir}/.ssh/id_snowbelle";
user = "blake"; user = "blake";
}; };
"zygarde" = {
hostname = "zygarde";
user = "blake";
identityFile = "${home_dir}/.ssh/id_snowbelle";
};
}; };
sops.secrets = { sops.secrets = {
+1 -1
View File
@@ -37,7 +37,7 @@ in {
identityFile = "${home_dir}/.ssh/id_snowbelle"; identityFile = "${home_dir}/.ssh/id_snowbelle";
port = 7567; port = 7567;
}; };
"bebe" = { "shauna" = {
hostname = "10.10.0.1"; hostname = "10.10.0.1";
user = "root"; user = "root";
identityFile = "${home_dir}/.ssh/id_snowbelle"; identityFile = "${home_dir}/.ssh/id_snowbelle";
+7 -1
View File
@@ -28,6 +28,7 @@ in {
# import snowbelle specific ssh keys # import snowbelle specific ssh keys
programs.ssh.settings = lib.mkForce { programs.ssh.settings = lib.mkForce {
"git.holocron.blue" = { "git.holocron.blue" = {
#AddressFamily = "inet";
user = "gitea"; user = "gitea";
identityFile = "${home_dir}/.ssh/id_vaniville"; identityFile = "${home_dir}/.ssh/id_vaniville";
port = 7567; port = 7567;
@@ -37,7 +38,12 @@ in {
identityFile = "${home_dir}/.ssh/id_vaniville"; identityFile = "${home_dir}/.ssh/id_vaniville";
port = 7567; port = 7567;
}; };
"bebe" = { "lumiose" = {
hostname = "10.10.0.11";
user = "blake";
identityFile = "${home_dir}/.ssh/id_vaniville";
};
"shauna" = {
hostname = "10.10.0.1"; hostname = "10.10.0.1";
user = "root"; user = "root";
identityFile = "${home_dir}/.ssh/id_vaniville"; identityFile = "${home_dir}/.ssh/id_vaniville";