mirror of
https://github.com/NixOS/nixpkgs.git
synced 2025-06-09 19:13:26 +03:00
nixos/opensmtpd: run nixfmt as requested by ci
This commit is contained in:
parent
fb4ff06a4b
commit
69a8aba113
2 changed files with 24 additions and 20 deletions
|
@ -113,11 +113,13 @@ in
|
|||
source = "${cfg.package}/bin/smtpctl";
|
||||
};
|
||||
|
||||
services.mail.sendmailSetuidWrapper = lib.mkIf cfg.setSendmail
|
||||
(security.wrappers.smtpctl // {
|
||||
services.mail.sendmailSetuidWrapper = lib.mkIf cfg.setSendmail (
|
||||
security.wrappers.smtpctl
|
||||
// {
|
||||
source = "${sendmail}/bin/sendmail";
|
||||
program = "sendmail";
|
||||
});
|
||||
}
|
||||
);
|
||||
|
||||
systemd.tmpfiles.rules = [
|
||||
"d /var/spool/smtpd 711 root - - -"
|
||||
|
|
|
@ -16,24 +16,26 @@ import ./make-test-python.nix {
|
|||
}
|
||||
];
|
||||
};
|
||||
environment.systemPackages = let
|
||||
testSendmail = pkgs.writeScriptBin "test-sendmail" ''
|
||||
#!/bin/sh
|
||||
set -euxo pipefail
|
||||
echo "========= SENDING" >&2
|
||||
${pkgs.system-sendmail}/bin/sendmail -v -f alice@smtp1 bob@smtp2 >&2 <<EOF
|
||||
From: alice@smtp1
|
||||
To: bob@smtp2
|
||||
Subject: Sendmail Test
|
||||
environment.systemPackages =
|
||||
let
|
||||
testSendmail = pkgs.writeScriptBin "test-sendmail" ''
|
||||
#!/bin/sh
|
||||
set -euxo pipefail
|
||||
echo "========= SENDING" >&2
|
||||
${pkgs.system-sendmail}/bin/sendmail -v -f alice@smtp1 bob@smtp2 >&2 <<EOF
|
||||
From: alice@smtp1
|
||||
To: bob@smtp2
|
||||
Subject: Sendmail Test
|
||||
|
||||
Hello World
|
||||
EOF
|
||||
echo "=========== FINISHED SENDING" >&2
|
||||
'';
|
||||
in [
|
||||
pkgs.opensmtpd
|
||||
testSendmail
|
||||
];
|
||||
Hello World
|
||||
EOF
|
||||
echo "=========== FINISHED SENDING" >&2
|
||||
'';
|
||||
in
|
||||
[
|
||||
pkgs.opensmtpd
|
||||
testSendmail
|
||||
];
|
||||
services.opensmtpd = {
|
||||
enable = true;
|
||||
extraServerArgs = [ "-v" ];
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue