This repository has no description
7.0 kB
199 lines
1{
2 lib,
3 ...
4}:
5
6{
7 imports = [
8 ../../configs
9 ../../configs/ssh-redirect.nix
10 ../../configs/retiolum.nix
11 ../../configs/mailserver.nix
12 ../../configs/snappymail.nix
13 ../../configs/gsm-wiki.nix
14 ../../configs/monitoring/telegraf.nix
15 ../../configs/pair-programming.nix
16 ../../configs/nginx.nix
17 # Disabled: on nixpkgs 151fa4e rogue-talk's python312 closure needs
18 # python3.12-anyio-4.14.2, whose test_tls_connectable fails and which
19 # Hydra has not cached. Re-enable once that builds again.
20 # ../../configs/rogue-talk.nix
21
22 ../../configs/services/matrix
23 ../../configs/services/matrix/proxy.nix
24 ../../configs/services/matrix/cinny.nix
25 ../../configs/services/matrix/bridges/mautrix-whatsapp.nix
26 ../../configs/services/matrix/bridges/mautrix-signal.nix
27 ../../configs/services/matrix/bridges/heisenbridge.nix
28 ../../configs/services/matrix/bridges/mautrix-telegram.nix
29 ../../configs/services/matrix/bridges/mautrix-discord.nix
30 ../../configs/services/matrix/bridges/matrix-zulip-bridge.nix
31
32 ../../configs/services/pad
33
34 ../../configs/hass/proxy.nix
35 ../../configs/hermes-proxy.nix
36
37 # sync-containers
38 ../../configs/consul.nix
39 ../../configs/services/flix/container-host.nix
40 ../../configs/services/radio/container-host.nix
41 ../../configs/orange-host.nix
42 ../../configs/hotdog-host.nix
43
44 # other containers
45 ../../configs/riot.nix
46
47 # proxying of services
48 ../../configs/services/radio/proxy.nix
49 ../../configs/services/flix/proxy.nix
50 ../../configs/services/coms/jitsi.nix
51
52 # dns
53 ../../configs/dns/knot.nix
54
55 # video strreaming
56 ../../configs/cast.nix
57
58 # c-base ollama tunnel
59 ../../configs/c-base-ai-tunnel.nix
60
61 # debug stuff
62 ../../configs/websites/mergebot.lassul.us.nix
63
64 # autoupdates
65 ../../configs/autoupdate.nix
66
67 # vaultwarden
68 ../../configs/vaultwarden.nix
69
70 # download user
71 ../../configs/download-user.nix
72
73 # caldav calendar
74 ../../configs/radicale.nix
75
76 # lassul.us website
77 ../../configs/websites/lassulus.nix
78
79 # where.is.lassul.us (location from home-assistant on a map)
80 ../../configs/websites/where.is.lassul.us
81
82 # realwallpaper generator
83 ../../configs/realwallpaper.nix
84
85 # paste + cyberlocker
86 ../../configs/paste
87
88 # opencrow matrix bot
89 ../../configs/opencrow.nix
90
91 # document signing
92 ../../configs/docuseal.nix
93
94 # timeful availability polls (when.lassul.us)
95 ../../configs/timeful.nix
96
97 # request-and-approve booking page (book.lassul.us)
98 ../../configs/book.nix
99
100 # backups
101 ./backup.nix
102
103 # IPFS
104 ../../configs/services/flix/ipfs.nix
105
106 # n2n supernode (n2n.lassul.us)
107 ../../configs/n2n-supernode.nix
108
109 # pocket-id SSO IdP (id.lassul.us)
110 ../../configs/pocket-id.nix
111
112 # covibe co-vibing dashboard (covibe.lassul.us); disabled, not needed now
113 # ../../configs/covibe.nix
114
115 # omnigent agent meta-harness (omni.lassul.us)
116 ../../configs/omnigent.nix
117
118 # radicle public seed (radicle.lassul.us)
119 ../../configs/radicle.lassul.us.nix
120 # radicle identity + node for this machine (/var/lib/rad)
121 ../../configs/rad.nix
122
123 # herdr agent multiplexer
124 ../../configs/herdr.nix
125
126 # self-hosted iroh relay (relay.lassul.us)
127 ../../configs/iroh-relay
128
129 # signed remote command execution (root executor + fleet dashboard,
130 # sigexec.lassul.us)
131 ../../configs/sigexec/executor.nix
132 ../../configs/sigexec/dashboard.nix
133
134 # parley federated IRC-speaking chat (parley.lassul.us)
135 ../../configs/parley.nix
136
137 # nixpkgs PR triage dashboard (review.lassul.us)
138 ../../configs/nixpkgs-triage.nix
139
140 # build farm (grpc://neoprism.r:50051) + binary cache (cache.lassul.us,
141 # niks3.lassul.us)
142 ../../configs/nix-farm/cache.nix
143 ../../configs/nix-farm/builder.nix
144 ];
145
146 # lassul.us shouldn't be the default vhost here (nginx.nix already sets one)
147 services.nginx.virtualHosts."lassul.us" = {
148 default = lib.mkForce false;
149 locations = {
150 "= /wallpaper-marker.png".extraConfig = ''
151 alias /var/realwallpaper/realwallpaper-marker.png;
152 '';
153 "= /wallpaper.png".extraConfig = ''
154 alias /var/realwallpaper/realwallpaper.png;
155 '';
156 "= /wallpaper-stars-berlin.png".extraConfig = ''
157 alias /var/realwallpaper/realwallpaper-krebs-stars-berlin.png;
158 '';
159 };
160 };
161
162 # riot VM (HFOS): fresh libvirt guest on a dedicated bridged public IP.
163 # Bridged onto ext-br with its own Hetzner MAC, so libvirt manages no
164 # firewall rules for it -> no nat-chain race, no restart-iptables hack (cf. hfos.nix).
165 virtualisation.libvirtd.enable = true;
166 security.polkit.enable = true;
167 users.users.riot = {
168 isNormalUser = true;
169 extraGroups = [ "libvirtd" ];
170 openssh.authorizedKeys.keys = [
171 "ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAACAQCwcI8EKqUwYVd4IlnTTaNY3qVMDe2M1sVPMdWaTJ8FnAXixBcZozFHyJ9bvGn6c/vFGBEACZk6QCxC2+sTxbaodCOUIyhAtxqAGO7jINmGrVWjg2NW8qBi+e+ekr2+jlhizxgMPgMcbawuazpMzrozi6sfJfRelJRqe6TxrK/SBO+V5pf8v2ubAfHHF6bJrqAykC247d2NmsHEyM/nGOOb2AlJx2vrK1FbFWr2fBAvnhJww9wqrfDYSM6+oRF/vrYKkT9cU8yjtCkyaJZTqRufF2pzc9a0X3Z4LHEIUykAl2aVmi5Wzh8CZj3qCeVb9Ju0ZGQIa5pvG5CbH5SUJOr9y6zhTx1xbqL+JYGkJqgHPMOCFiNIvWnFaNlnvFf4C9KcTf/VMOEvNdDklpjoWm+ptuQIciAhWKuUHd/6MqaRjmlvUqjl49EkRvYOGn9vasKt66MYrtfvbZ3tcqh5w9EEKhrcygiUXhIJzhu2s1BseAVRLjCsQ24BNbzrYiCO+vuk8/hdeHB1rP6Sas2v7jvYb3zQd647OTq+HrZWN8aCjCs5h8Y0QxrQzsLru0zKDRaNDlbSshNBAw7PzSXQAf9fISH7v6sC4nstf5jk+87ua/7xjWG4NYp5Y9FMFCsuE3XVmUCAbauq18RmN6V4s2TxCEs9bxONO0Vba4zwPnvMlw== cardno:000619250765"
172 ];
173 };
174 # the only forwarding the VM needs: accept traffic to/from its public IP.
175 networking.firewall.extraForwardRules = ''
176 ip daddr 95.217.192.52 accept
177 ip saddr 95.217.192.52 accept
178 '';
179
180 # tank/radicle (radicle seed storage) is created by disko at install; on an
181 # already-provisioned host it must be created before deploying:
182 # zfs create -o mountpoint=/var/lib/radicle -o quota=80G tank/radicle
183 # nofail keeps a missing dataset from failing local-fs.target -> emergency
184 # mode (which has no network and bricks the box).
185 fileSystems."/var/lib/radicle".options = [ "nofail" ];
186
187 # Fleet-wide safety net: this box is headless (Hetzner, console only via
188 # KVM), so a failed critical target must never strand us at the emergency
189 # shell. With emergency mode disabled systemd keeps booting instead of
190 # dropping to a console -> network + sshd still come up, so a bad deploy
191 # (e.g. a missing dataset, as happened once) leaves the box reachable to
192 # fix and redeploy rather than bricked. Mirrors nixpkgs' headless profile.
193 # Note: we intentionally do NOT auto-roll-back to the previous generation;
194 # our config is pulled from git by system.autoUpgrade, so a rollback would
195 # just re-pull the same broken config on the next run (a rollback loop).
196 systemd.enableEmergencyMode = false;
197
198 system.stateVersion = "24.05";
199}