mirror of
https://github.com/oddlama/nix-config.git
synced 2025-10-10 23:00:39 +02:00
fix: generators can't output newline-free files
This commit is contained in:
parent
65ca9a35c5
commit
f4a0923f5a
2 changed files with 3 additions and 2 deletions
|
@ -55,7 +55,6 @@
|
||||||
${decrypt} ${lib.escapeShellArg dep.file} \
|
${decrypt} ${lib.escapeShellArg dep.file} \
|
||||||
| tr -d '\n' \
|
| tr -d '\n' \
|
||||||
| ${pkgs.libargon2}/bin/argon2 "$(${pkgs.openssl}/bin/openssl rand -base64 16)" -id -e \
|
| ${pkgs.libargon2}/bin/argon2 "$(${pkgs.openssl}/bin/openssl rand -base64 16)" -id -e \
|
||||||
| tr -d '\n' \
|
|
||||||
|| die "Failure while generating argon2id hash"
|
|| die "Failure while generating argon2id hash"
|
||||||
'';
|
'';
|
||||||
|
|
||||||
|
|
|
@ -66,7 +66,7 @@ in {
|
||||||
lib.mkForce {
|
lib.mkForce {
|
||||||
authentication.fallback-admin = {
|
authentication.fallback-admin = {
|
||||||
user = "admin";
|
user = "admin";
|
||||||
secret = "%{file:${config.age.secrets.stalwart-admin-hash.path}}%";
|
secret = "%{file:/run/stalwart-mail/admin-hash}%";
|
||||||
};
|
};
|
||||||
|
|
||||||
tracer.stdout = {
|
tracer.stdout = {
|
||||||
|
@ -478,6 +478,8 @@ in {
|
||||||
in {
|
in {
|
||||||
preStart = lib.mkAfter ''
|
preStart = lib.mkAfter ''
|
||||||
cat ${configFile} > /run/stalwart-mail/config.toml
|
cat ${configFile} > /run/stalwart-mail/config.toml
|
||||||
|
cat ${config.age.secrets.stalwart-admin-hash.path} \
|
||||||
|
| tr -d '\n' > /run/stalwart-mail/admin-hash
|
||||||
'';
|
'';
|
||||||
serviceConfig = {
|
serviceConfig = {
|
||||||
RuntimeDirectory = "stalwart-mail";
|
RuntimeDirectory = "stalwart-mail";
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue