fix(secrets): fix permissions

Also moves key references into respective configs where they are used.
This commit is contained in:
Felix Schröter 2022-05-06 03:16:17 +02:00
parent 7f3a5317bd
commit 0dee8b4fa7
Signed by: felschr
GPG key ID: 671E39E6744C807D
15 changed files with 125 additions and 96 deletions

View file

@ -5,7 +5,22 @@ with pkgs;
let
port = 1883;
wsPort = 9001;
mkSecret = file: {
inherit file;
owner = "mosquitto";
group = "mosquitto";
};
in {
age.secrets = {
mqtt-felix = mkSecret ../secrets/mqtt/felix.age;
mqtt-birgit = mkSecret ../secrets/mqtt/birgit.age;
mqtt-hass = mkSecret ../secrets/mqtt/hass.age;
mqtt-tasmota = mkSecret ../secrets/mqtt/tasmota.age;
mqtt-owntracks = mkSecret ../secrets/mqtt/owntracks.age;
mqtt-owntracks-plain = mkSecret ../secrets/mqtt/owntracks-plain.age;
};
services.nginx = {
virtualHosts."mqtt.felschr.com" = {
enableACME = true;