chore(nix): add coturn secrets

This commit is contained in:
Serĉanto de Scio 2024-08-24 19:54:26 +10:00
parent d87c0e5ba1
commit 318c10991c
Signed by: sercanto
GPG key ID: A4122FF3971B6865
3 changed files with 42 additions and 1 deletions

View file

@ -5,7 +5,12 @@
lib,
...
}: {
imports = [../secrets/coturn.nix];
age.secrets = {
file = ../secrets/coturn.age;
owner = "turnserver";
group = "turnserver";
mode = "0640";
};
services = {
coturn = {
@ -20,6 +25,7 @@
no-tcp-relay = true; # Disable TCP relay endpoints
extraConfig = "\n cipher-list=\"HIGH\"\n no-loopback-peers\n no-multicast-peers\n ";
secure-stun = true; # Require authentication of the STUN Binding request
static-auth-secret-file = config.age.secrets.coturn.path;
cert = "/var/lib/acme/turn.mcwhirter.io/fullchain.pem";
pkey = "/var/lib/acme/turn.mcwhirter.io/key.pem";
min-port = 49152; # Lower bound of UDP relay endpoints

34
secrets/coturn.age Normal file
View file

@ -0,0 +1,34 @@
-----BEGIN AGE ENCRYPTED FILE-----
YWdlLWVuY3J5cHRpb24ub3JnL3YxCi0+IHNzaC1lZDI1NTE5IEZCOVgxUSBvZnl0
SlZNd0hkT2JqRjJMTzNqYjhhYjVGZ0tneXcrN004QnFkb0VrWjNFCm1ibVRMSmFX
QzdOZGZ2SnVkRnozR1Iycmx1NkRwd1BVRk5WcUVqZ3dTbncKLT4gc3NoLWVkMjU1
MTkgSk00dDZBIGlHSnRpazVOdDNrdS8ydUh0UFk4UUZPWm12eUI5RE04b213RjRJ
cVB3bjAKS2diZVhkcEt1SjF3UjdNaCs1anJOZVJCdERXcGgvNGNKUHdwYUN6eWI4
VQotPiBzc2gtZWQyNTUxOSA5aEV5RFEgdGJ2UUM4aTRCaEtTaitZK2ZpUklSZGt1
SHAxM1VlVmk0UnFoSW9GSFduTQpkeGdsRVNTaXNpeThQTHVrTEk5ZjVIczdTMmlS
QW9HZmhnTXFQTThUdjhBCi0+IHNzaC1lZDI1NTE5IHU3WjNqdyBxTmNkS2hTTm9N
TWVVcG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UvUlV4OE9ZclQ2a04zaWgyRTRLRFEKRWhoNXBBM0lTekZz
L1dLRUxSZGRWdjk2NXpvMmMxelFuQlhjRlB3WWZ6YwotPiBzc2gtZWQyNTUxOSB6
RzMrMXcgeUd4RmNubUhYSjZ3OGxwbXhrU1BUMjJZOG43REZlVytKOUZTUk9VZ29T
SQp2ejVBUFQvSENobkZYeXhtclF3WlhkRmZkeEZYRndTL1ZxQmFOS2JhMmRFCi0+
ICRFem5RWUpCLWdyZWFzZSBTd2oKa3hoS2hGbmcKLS0tIHF0cE1qZ1pBVTlDNFRZ
NW9remMrQXFNcUtuSExUYVBCMUdDRlAvNmxjbW8KUAoiwUuHK+yU3xvGO0FPQkAC
f6Eh7OB60axF4L60rAmQBicoBISMZy+pvnb+ddRY0mH/jhoi7eP2mdmlFRwi8b1K
A/kLHj37lOLbE0sjaYUQTnlGIKWj0oa3apcLwc7wOw==
-----END AGE ENCRYPTED FILE-----

View file

@ -43,6 +43,7 @@ in {
"hamish.age".publicKeys = ops ++ systems;
"logan.age".publicKeys = ops ++ systems;
"xander.age".publicKeys = ops ++ systems;
"coturn.age".publicKeys = ops ++ systems;
"nextcloud-dbpass.age".publicKeys = ops ++ systems;
"nextcloud-adminpass.age".publicKeys = ops ++ systems;
"tt-rss-dbpass.age".publicKeys = ops ++ systems;