Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 5 additions & 7 deletions nixos/modules/services/mail/sympa.nix
Original file line number Diff line number Diff line change
Expand Up @@ -25,8 +25,6 @@ let
StateDirectory = "sympa";
ProtectHome = true;
ProtectSystem = "full";
ProtectKernelTunables = true;
ProtectKernelModules = true;
ProtectControlGroups = true;
};

Expand Down Expand Up @@ -415,7 +413,7 @@ in
# force-copy static_content so it's up to date with package
# set permissions for wwsympa which needs write access (...)
"R ${dataDir}/static_content - - - - -"
"C ${dataDir}/static_content 0711 ${user} ${group} - ${pkg}/static_content"
"C ${dataDir}/static_content 0711 ${user} ${group} - ${pkg}/var/lib/sympa/static_content"
"e ${dataDir}/static_content/* 0711 ${user} ${group} - -"

"d /run/sympa 0755 ${user} ${group} - -"
Expand Down Expand Up @@ -497,7 +495,7 @@ in
-F ${toString cfg.web.fcgiProcs} \
-P /run/sympa/wwsympa.pid \
-s /run/sympa/wwsympa.socket \
-- ${pkg}/bin/wwsympa.fcgi
-- ${pkg}/lib/sympa/cgi/wwsympa.fcgi
'';

} // commonServiceConfig;
Expand All @@ -518,7 +516,7 @@ in
fastcgi_split_path_info ^(${loc})(.*)$;

fastcgi_param PATH_INFO $fastcgi_path_info;
fastcgi_param SCRIPT_FILENAME ${pkg}/bin/wwsympa.fcgi;
fastcgi_param SCRIPT_FILENAME ${pkg}/lib/sympa/cgi/wwsympa.fcgi;
'';
}) // {
"/static-sympa/".alias = "${dataDir}/static_content/";
Expand Down Expand Up @@ -550,7 +548,7 @@ in
args = [
"flags=hqRu"
"user=${user}"
"argv=${pkg}/bin/queue"
"argv=${pkg}/libexec/queue"
"\${nexthop}"
];
};
Expand All @@ -562,7 +560,7 @@ in
args = [
"flags=hqRu"
"user=${user}"
"argv=${pkg}/bin/bouncequeue"
"argv=${pkg}/libexec/bouncequeue"
"\${nexthop}"
];
};
Expand Down
12 changes: 8 additions & 4 deletions pkgs/servers/mail/sympa/default.nix
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
{ stdenv, perl, fetchFromGitHub, autoreconfHook
}:
{ stdenv, perl, fetchFromGitHub, autoreconfHook, nixosTests }:

let
dataDir = "/var/lib/sympa";
Expand Down Expand Up @@ -64,16 +63,17 @@ let
in
stdenv.mkDerivation rec {
pname = "sympa";
version = "6.2.52";
version = "6.2.54";

src = fetchFromGitHub {
owner = "sympa-community";
repo = pname;
rev = version;
sha256 = "071kx6ryifs2f6fhfky9g297frzp5584kn444af1vb2imzydsbnh";
sha256 = "07wfvr8rrg7pwkl2zglrdri7n42rl9gwrjbaffb8m37wq67s7fca";
};

configureFlags = [
"--enable-fhs"
"--without-initdir"
"--without-unitsdir"
"--without-smrshdir"
Expand Down Expand Up @@ -106,6 +106,10 @@ stdenv.mkDerivation rec {
rm -rf "$TMP/bin"
'';

passthru.tests = {
inherit (nixosTests) sympa;
};

meta = with stdenv.lib; {
description = "Open source mailing list manager";
homepage = "https://www.sympa.org";
Expand Down