Files
nixpkgs/nixos/tests/roundcube.nix
Maximilian Bosch e9d0fe01f7 nixos/roundcube: use python assertion for inspecting response
That way we always see what's being returned.
2026-05-14 18:25:29 +02:00

39 lines
943 B
Nix

{ pkgs, ... }:
{
name = "roundcube";
meta = {
maintainers = [ ];
};
nodes = {
roundcube =
{ config, pkgs, ... }:
{
services.roundcube = {
enable = true;
hostName = "roundcube";
database.password = "not production";
package = pkgs.roundcube.withPlugins (plugins: [ plugins.persistent_login ]);
plugins = [ "persistent_login" ];
dicts = with pkgs.aspellDicts; [
en
fr
de
];
};
services.nginx.virtualHosts.roundcube = {
forceSSL = false;
enableACME = false;
};
};
};
testScript = ''
roundcube.start
roundcube.wait_for_unit("postgresql.target")
roundcube.wait_for_unit("phpfpm-roundcube.service")
roundcube.wait_for_unit("nginx.service")
t.assertIn("Keep me logged in", roundcube.succeed("curl -sSfL http://roundcube/"))
'';
}