From 4b8fee227424154cb455ca745e633303ab6405d8 Mon Sep 17 00:00:00 2001 From: Yaroslav Bolyukin Date: Fri, 15 Nov 2024 21:05:56 +0100 Subject: [PATCH] nixos/netbird: fix coturn configuration --- nixos/modules/services/networking/netbird/coturn.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/nixos/modules/services/networking/netbird/coturn.nix b/nixos/modules/services/networking/netbird/coturn.nix index 29ff1e8fc15e..442b2dadba2b 100644 --- a/nixos/modules/services/networking/netbird/coturn.nix +++ b/nixos/modules/services/networking/netbird/coturn.nix @@ -131,8 +131,8 @@ in ${getExe pkgs.replace-secret} @password@ ${cfg.passwordFile} /run/coturn/turnserver.cfg '') + (optionalString cfg.useAcmeCertificates '' - ${getExe pkgs.replace-secret} @cert@ "$CREDENTIALS_DIRECTORY/cert.pem" /run/coturn/turnserver.cfg - ${getExe pkgs.replace-secret} @pkey@ "$CREDENTIALS_DIRECTORY/pkey.pem" /run/coturn/turnserver.cfg + ${getExe pkgs.replace-secret} @cert@ <(echo -n "$CREDENTIALS_DIRECTORY/cert.pem") /run/coturn/turnserver.cfg + ${getExe pkgs.replace-secret} @pkey@ <(echo -n "$CREDENTIALS_DIRECTORY/pkey.pem") /run/coturn/turnserver.cfg ''); in (optionalAttrs (preStart' != "") { preStart = mkAfter preStart'; })