diff --git a/srcpkgs/maddy/INSTALL b/srcpkgs/maddy/INSTALL new file mode 100644 index 00000000000..84b9d3eadf1 --- /dev/null +++ b/srcpkgs/maddy/INSTALL @@ -0,0 +1,5 @@ +case "$ACTION" in +post) + setcap 'cap_net_bind_service=+ep' /usr/bin/maddy + ;; +esac diff --git a/srcpkgs/maddy/files/maddy/run b/srcpkgs/maddy/files/maddy/run index ad2233b6694..d9036916b86 100644 --- a/srcpkgs/maddy/files/maddy/run +++ b/srcpkgs/maddy/files/maddy/run @@ -1,4 +1,6 @@ #!/bin/sh umask 0027 exec 2>&1 +mkdir -p /run/maddy +chown _maddy:_maddy /run/maddy exec chpst -u _maddy:_maddy -C /var/lib/maddy -o 131072 -p 512 /usr/bin/maddy run diff --git a/srcpkgs/maddy/template b/srcpkgs/maddy/template index 732a3c14475..87f48f2c3c7 100644 --- a/srcpkgs/maddy/template +++ b/srcpkgs/maddy/template @@ -1,6 +1,6 @@ # Template file for 'maddy' pkgname=maddy -version=0.7.1 +version=0.8.1 revision=1 build_style=go go_import_path="github.com/foxcpp/maddy" @@ -9,12 +9,13 @@ go_package="$go_import_path/cmd/maddy $go_import_path/cmd/maddy-shadow-helper" hostmakedepends="scdoc" makedepends="pam-devel" +depends="libcap-progs" # For setcap(8) short_desc="Composable all-in-one mail server" maintainer="Michael Aldridge " license="GPL-3.0-or-later" homepage="https://maddy.email" distfiles="https://github.com/foxcpp/maddy/archive/refs/tags/v$version.tar.gz" -checksum=541288477afb040a04a5cf17a1c3e3b7a81b287dc3a81c844b2d6ad66688c29e +checksum=e31decff5df3e9f70aba9f27e4cb62d925263aa6e75671685236d08a589dfd8b make_dirs="/var/lib/maddy 0750 _maddy _maddy /etc/maddy 0750 _maddy _maddy" system_accounts="_maddy"