chore(rosenpass): Add integration tests for basic connectivity, backwards compatability and multi-peer connectivity

This commit is contained in:
David Niehues
2025-07-07 12:19:44 +02:00
parent b5ef5842d9
commit dddadb67b8
12 changed files with 1082 additions and 0 deletions

View File

@@ -0,0 +1,38 @@
{
lib,
pkgs,
config,
...
}:
let
cfg = config.services.rosenpassKeyExchange;
in
{
options.services.rosenpassKeyExchange = {
enable = lib.mkEnableOption "rosenpass key-exchange";
config = lib.mkOption {
type = lib.types.path;
description = "Path to rosenpass configuration";
};
rosenpassVersion = lib.mkOption {
type = lib.types.package;
description = "Rosenpass package to use";
};
};
config = lib.mkIf cfg.enable {
systemd.services.rp-exchange = {
description = "Rosenpass Key Exchanger";
wantedBy = [ "multi-user.target" ];
requires = [ "network-online.target" ];
script = ''
${cfg.rosenpassVersion}/bin/rosenpass exchange-config ${cfg.config}
'';
serviceConfig = {
Restart = "always";
RestartSec = 1;
};
};
};
}