12 Commits

Author SHA1 Message Date
83c11bb06e Merge pull request 'add pretalx' (#132) from pretalx into master
All checks were successful
Check flake syntax / flake-check (push) Successful in 11m21s
Reviewed-on: #132
2026-03-07 16:16:26 +01:00
cd5db6a616 [pretalx] fix wrong import
All checks were successful
Check flake syntax / flake-check (push) Successful in 5m30s
2026-03-07 16:10:07 +01:00
e32e4d7774 [pretalx] enable admin user
Some checks failed
Check flake syntax / flake-check (push) Failing after 5m56s
2026-03-07 16:03:02 +01:00
c3474f9c27 [pretalx] proxy through vpn
Some checks failed
Check flake syntax / flake-check (push) Has been cancelled
2026-03-07 16:01:47 +01:00
e021f46b4d [vaultwarden] fix missing input
All checks were successful
Check flake syntax / flake-check (push) Successful in 9m17s
2026-03-06 12:07:56 +01:00
ff340d69fb [fanny] deploy pretalx 2026-03-06 12:07:56 +01:00
56c1ae5332 [vaultwarden] add monitoring 2026-03-06 12:07:56 +01:00
bbf8decea1 [pretalx] add monitoring 2026-03-06 12:07:56 +01:00
a1bfa0120c [pretalx] init 2026-03-06 12:07:56 +01:00
malobot
344eeb437b Update flake.lock
All checks were successful
Check flake syntax / flake-check (push) Successful in 6m27s
Weekly Flake Update / update_and_check_flake (push) Successful in 6m0s
2026-02-26 00:03:38 +00:00
d5767508ef [louise] add bitwarden-desktop
All checks were successful
Check flake syntax / flake-check (push) Successful in 8m26s
Weekly Flake Update / update_and_check_flake (push) Successful in 6m3s
2026-02-23 01:04:54 +01:00
a07b8ffd68 [run-vm] add testHost option to module to allow local testing again
All checks were successful
Check flake syntax / flake-check (push) Successful in 5m40s
2026-02-22 21:48:18 +01:00
10 changed files with 175 additions and 59 deletions

80
flake.lock generated
View File

@@ -7,11 +7,11 @@
] ]
}, },
"locked": { "locked": {
"lastModified": 1746728054, "lastModified": 1768920986,
"narHash": "sha256-eDoSOhxGEm2PykZFa/x9QG5eTH0MJdiJ9aR00VAofXE=", "narHash": "sha256-CNzzBsRhq7gg4BMBuTDObiWDH/rFYHEuDRVOwCcwXw4=",
"owner": "nix-community", "owner": "nix-community",
"repo": "disko", "repo": "disko",
"rev": "ff442f5d1425feb86344c028298548024f21256d", "rev": "de5708739256238fb912c62f03988815db89ec9a",
"type": "github" "type": "github"
}, },
"original": { "original": {
@@ -78,24 +78,6 @@
"type": "github" "type": "github"
} }
}, },
"flake-utils_2": {
"inputs": {
"systems": "systems_3"
},
"locked": {
"lastModified": 1731533236,
"narHash": "sha256-l0KFg5HjrsfsO/JpG+r7fRrqm12kzFHyUHqHCVpMMbI=",
"owner": "numtide",
"repo": "flake-utils",
"rev": "11707dc2f618dd54ca8739b309ec4fc024de578b",
"type": "github"
},
"original": {
"owner": "numtide",
"repo": "flake-utils",
"type": "github"
}
},
"home-manager": { "home-manager": {
"inputs": { "inputs": {
"nixpkgs": [ "nixpkgs": [
@@ -138,18 +120,17 @@
}, },
"microvm": { "microvm": {
"inputs": { "inputs": {
"flake-utils": "flake-utils_2",
"nixpkgs": [ "nixpkgs": [
"nixpkgs" "nixpkgs"
], ],
"spectrum": "spectrum" "spectrum": "spectrum"
}, },
"locked": { "locked": {
"lastModified": 1764549796, "lastModified": 1772055583,
"narHash": "sha256-Mswg665P92EoHkBwCwPr/7bdnj04g2Qfb+t02ZEYTHA=", "narHash": "sha256-iPIm1orqkhsxqju6EVODOrV1BmyA5HNTZ8a1o812bFM=",
"owner": "astro", "owner": "astro",
"repo": "microvm.nix", "repo": "microvm.nix",
"rev": "030d055e877cc13d7525b39f434150226d5e4482", "rev": "f6dcfb7c16cc3775536c825dc0698d4ede13d063",
"type": "github" "type": "github"
}, },
"original": { "original": {
@@ -181,11 +162,11 @@
] ]
}, },
"locked": { "locked": {
"lastModified": 1764234087, "lastModified": 1769813415,
"narHash": "sha256-NHF7QWa0ZPT8hsJrvijREW3+nifmF2rTXgS2v0tpcEA=", "narHash": "sha256-nnVmNNKBi1YiBNPhKclNYDORoHkuKipoz7EtVnXO50A=",
"owner": "nix-community", "owner": "nix-community",
"repo": "nixos-generators", "repo": "nixos-generators",
"rev": "032a1878682fafe829edfcf5fdfad635a2efe748", "rev": "8946737ff703382fda7623b9fab071d037e897d5",
"type": "github" "type": "github"
}, },
"original": { "original": {
@@ -196,11 +177,11 @@
}, },
"nixos-hardware": { "nixos-hardware": {
"locked": { "locked": {
"lastModified": 1764440730, "lastModified": 1771969195,
"narHash": "sha256-ZlJTNLUKQRANlLDomuRWLBCH5792x+6XUJ4YdFRjtO4=", "narHash": "sha256-qwcDBtrRvJbrrnv1lf/pREQi8t2hWZxVAyeMo7/E9sw=",
"owner": "NixOS", "owner": "NixOS",
"repo": "nixos-hardware", "repo": "nixos-hardware",
"rev": "9154f4569b6cdfd3c595851a6ba51bfaa472d9f3", "rev": "41c6b421bdc301b2624486e11905c9af7b8ec68e",
"type": "github" "type": "github"
}, },
"original": { "original": {
@@ -228,11 +209,11 @@
}, },
"nixpkgs-unstable": { "nixpkgs-unstable": {
"locked": { "locked": {
"lastModified": 1764517877, "lastModified": 1771848320,
"narHash": "sha256-pp3uT4hHijIC8JUK5MEqeAWmParJrgBVzHLNfJDZxg4=", "narHash": "sha256-0MAd+0mun3K/Ns8JATeHT1sX28faLII5hVLq0L3BdZU=",
"owner": "NixOS", "owner": "NixOS",
"repo": "nixpkgs", "repo": "nixpkgs",
"rev": "2d293cbfa5a793b4c50d17c05ef9e385b90edf6c", "rev": "2fc6539b481e1d2569f25f8799236694180c0993",
"type": "github" "type": "github"
}, },
"original": { "original": {
@@ -244,11 +225,11 @@
}, },
"nixpkgs_2": { "nixpkgs_2": {
"locked": { "locked": {
"lastModified": 1764522689, "lastModified": 1771903837,
"narHash": "sha256-SqUuBFjhl/kpDiVaKLQBoD8TLD+/cTUzzgVFoaHrkqY=", "narHash": "sha256-sdaqdnsQCv3iifzxwB22tUwN/fSHoN7j2myFW5EIkGk=",
"owner": "NixOS", "owner": "NixOS",
"repo": "nixpkgs", "repo": "nixpkgs",
"rev": "8bb5646e0bed5dbd3ab08c7a7cc15b75ab4e1d0f", "rev": "e764fc9a405871f1f6ca3d1394fb422e0a0c3951",
"type": "github" "type": "github"
}, },
"original": { "original": {
@@ -283,11 +264,11 @@
] ]
}, },
"locked": { "locked": {
"lastModified": 1764483358, "lastModified": 1772048434,
"narHash": "sha256-EyyvCzXoHrbL467YSsQBTWWg4sR96MH1sPpKoSOelB4=", "narHash": "sha256-/wA0OaH6kZ/pFA+nXR/tvg5oupOmEDmMS5us79JT60o=",
"owner": "Mic92", "owner": "Mic92",
"repo": "sops-nix", "repo": "sops-nix",
"rev": "5aca6ff67264321d47856a2ed183729271107c9c", "rev": "334daa7c273dd8bf7a0cd370e4e16022b64e55e9",
"type": "github" "type": "github"
}, },
"original": { "original": {
@@ -372,21 +353,6 @@
"type": "github" "type": "github"
} }
}, },
"systems_5": {
"locked": {
"lastModified": 1681028828,
"narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=",
"owner": "nix-systems",
"repo": "default",
"rev": "da67096a3b9bf56a91d16901293e51ba5b49a27e",
"type": "github"
},
"original": {
"owner": "nix-systems",
"repo": "default",
"type": "github"
}
},
"tasklist": { "tasklist": {
"inputs": { "inputs": {
"nixpkgs": [ "nixpkgs": [
@@ -445,7 +411,7 @@
}, },
"utils_3": { "utils_3": {
"inputs": { "inputs": {
"systems": "systems_4" "systems": "systems_3"
}, },
"locked": { "locked": {
"lastModified": 1731533236, "lastModified": 1731533236,
@@ -463,7 +429,7 @@
}, },
"utils_4": { "utils_4": {
"inputs": { "inputs": {
"systems": "systems_5" "systems": "systems_4"
}, },
"locked": { "locked": {
"lastModified": 1731533236, "lastModified": 1731533236,

View File

@@ -63,6 +63,16 @@ in
}; };
}; };
services.nginx.virtualHosts."talks.malobeo.org" = {
forceSSL = true;
enableACME= true;
locations."/" = {
proxyPass = "http://10.0.0.10";
extraConfig = ''
'';
};
};
services.nginx.virtualHosts."tasklist.malobeo.org" = { services.nginx.virtualHosts."tasklist.malobeo.org" = {
forceSSL = true; forceSSL = true;
enableACME= true; enableACME= true;

View File

@@ -145,6 +145,7 @@ in
"durruti" "durruti"
"zineshop" "zineshop"
"vaultwarden" "vaultwarden"
"pretalx"
]; ];
networking = { networking = {
@@ -229,6 +230,15 @@ in
}; };
}; };
virtualHosts."talks.malobeo.org" = {
locations."/" = {
proxyPass = "http://${hosts.malobeo.hosts.pretalx.network.address}";
extraConfig = ''
proxy_set_header Host $host;
'';
};
};
virtualHosts."tasklist.malobeo.org" = { virtualHosts."tasklist.malobeo.org" = {
locations."/" = { locations."/" = {
proxyPass = "http://${hosts.malobeo.hosts.durruti.network.address}:8080"; proxyPass = "http://${hosts.malobeo.hosts.durruti.network.address}:8080";

View File

@@ -103,6 +103,11 @@ in
type = "microvm"; type = "microvm";
network = createMaloNet "17" "52:DA:0D:F9:EF:F3"; network = createMaloNet "17" "52:DA:0D:F9:EF:F3";
}; };
pretalx = {
type = "microvm";
network = createMaloNet "18" "52:DA:0D:F9:EF:F4";
};
}; };
}; };
} }

View File

@@ -42,6 +42,7 @@
mpv mpv
vlc vlc
simple-scan simple-scan
bitwarden-desktop
]; ];
}; };

View File

@@ -14,6 +14,12 @@ in
description = lib.mdDoc "Setup bridge device for microvms."; description = lib.mdDoc "Setup bridge device for microvms.";
}; };
testHost = mkOption {
default = false;
type = types.bool;
description = lib.mdDoc "Enable when the host is used for development and testing using run-vm";
};
interface = mkOption { interface = mkOption {
default = "eno1"; default = "eno1";
type = types.str; type = types.str;
@@ -68,7 +74,7 @@ in
systemd.network = mkIf (cfg.enableHostBridge || cfg.enableHostBridgeUnstable) { systemd.network = mkIf (cfg.enableHostBridge || cfg.enableHostBridgeUnstable) {
enable = true; enable = true;
networks."10-lan" = { networks."10-lan" = {
matchConfig.Name = [ "${cfg.interface}" "vm-*"]; matchConfig.Name = ["vm-*"] ++ (if !cfg.testHost then [ "${cfg.interface}" ] else [ ]);
networkConfig = { networkConfig = {
Bridge = "malobeo0"; Bridge = "malobeo0";
}; };
@@ -81,7 +87,7 @@ in
}; };
}; };
networks."10-lan-bridge" = { networks."10-lan-bridge" = if !cfg.testHost then {
matchConfig.Name = "malobeo0"; matchConfig.Name = "malobeo0";
networkConfig = { networkConfig = {
Address = [ "${cfg.address}" ]; Address = [ "${cfg.address}" ];
@@ -90,6 +96,17 @@ in
IPv6AcceptRA = true; IPv6AcceptRA = true;
}; };
linkConfig.RequiredForOnline = "routable"; linkConfig.RequiredForOnline = "routable";
} else {
matchConfig.Name = "malobeo0";
networkConfig = {
DHCPServer = true;
IPv6SendRA = true;
};
addresses = if cfg.enableHostBridgeUnstable then [
{ Address = "10.0.0.1/24"; }
] else [
{ Address = "10.0.0.1/24"; }
];
}; };
}; };

View File

@@ -144,6 +144,18 @@ in
targets = [ "${hosts.malobeo.hosts.zineshop.network.address}:9002" ]; targets = [ "${hosts.malobeo.hosts.zineshop.network.address}:9002" ];
}]; }];
} }
{
job_name = "vaultwarden";
static_configs = [{
targets = [ "${hosts.malobeo.hosts.vaultwarden.network.address}:9002" ];
}];
}
{
job_name = "pretalx";
static_configs = [{
targets = [ "${hosts.malobeo.hosts.pretalx.network.address}:9002" ];
}];
}
{ {
job_name = "fanny"; job_name = "fanny";
static_configs = [{ static_configs = [{

View File

@@ -0,0 +1,79 @@
{ config, self, lib, pkgs, ... }:
with lib;
let
hosts = import ../hosts.nix {};
in
{
networking = {
hostName = mkDefault "pretalx";
useDHCP = false;
};
imports = [
self.nixosModules.malobeo.metrics
self.nixosModules.malobeo.users
../modules/sshd.nix
../modules/minimal_tools.nix
../modules/autoupdate.nix
];
malobeo.metrics = {
enable = true;
enablePromtail = true;
logNginx = true;
};
malobeo.users = {
admin = true;
};
services.postgresqlBackup = {
enable = true;
};
services.nginx = {
enable = true;
commonHttpConfig = /* nginx */ ''
proxy_headers_hash_bucket_size 64;
'';
virtualHosts = {
"talks.malobeo.org" = {
forceSSL = false;
enableACME = false;
};
};
};
services.pretalx = {
enable = true;
celery.extraArgs = [
"--concurrency=${toString config.microvm.vcpu}"
];
gunicorn.extraArgs = [
# https://docs.pretalx.org/administrator/installation/#step-6-starting-pretalx-as-a-service
"--log-level=info"
"--max-requests-jitter=50"
"--max-requests=1200"
"--workers=${toString config.microvm.vcpu}"
# TODO: 25.11 upstream
"--name=pretalx"
"--preload"
];
nginx.domain = "talks.malobeo.org";
settings = {
locale = {
language_code = "de";
};
};
};
networking.firewall.allowedTCPPorts = [ 80 443 ];
system.stateVersion = "22.11"; # Did you read the comment?
}

View File

@@ -18,10 +18,17 @@ with lib;
imports = [ imports = [
../modules/malobeo_user.nix ../modules/malobeo_user.nix
../modules/sshd.nix ../modules/sshd.nix
inputs.self.nixosModules.malobeo.metrics
]; ];
networking.firewall.allowedTCPPorts = [ 80 ]; networking.firewall.allowedTCPPorts = [ 80 ];
malobeo.metrics = {
enable = true;
enablePromtail = true;
logNginx = true;
};
services.nginx = { services.nginx = {
enable = true; enable = true;
virtualHosts."keys.malobeo.org" = { virtualHosts."keys.malobeo.org" = {

View File

@@ -58,6 +58,15 @@ with lib;
}; };
}; };
virtualHosts."talks.malobeo.org" = {
locations."/" = {
proxyPass = "http://10.100.0.101";
extraConfig = ''
proxy_set_header Host $host;
'';
};
};
virtualHosts."tasklist.malobeo.org" = { virtualHosts."tasklist.malobeo.org" = {
locations."/" = { locations."/" = {
proxyPass = "http://10.100.0.101"; proxyPass = "http://10.100.0.101";