add readeck

This commit is contained in:
Joakim Repomaa
2025-02-11 23:10:17 +02:00
parent 0bc01cd2b1
commit cfa04ddc31
6 changed files with 54 additions and 1 deletions

View File

@@ -6,6 +6,7 @@
"gotosocial"
"hastebin-tokens"
"immich"
"readeck"
"storage-box-credentials"
"vaultwarden"
]

View File

@@ -105,6 +105,18 @@ in
enable = true;
subdomain = "bin";
};
};
readeck = {
enable = true;
subdomain = "read";
settings.email = {
host = smtp.host;
port = smtp.port;
username = smtp.username;
encryption = "starttls";
from = smtp.from;
from_noreply = smtp.from;
};
};
};
}

View File

@@ -14,5 +14,6 @@
./gotosocial.nix
./hastebin.nix
./workout-sync.nix
./readeck.nix
];
}

View File

@@ -0,0 +1,38 @@
{ lib, inputs, config, pkgs, ... }:
let
cfg = config.services.readeck;
secrets = config.age.secrets;
fqdn = "${cfg.subdomain}.${config.networking.domain}";
pkgsUnstable = inputs.nixpkgs-unstable.legacyPackages.${pkgs.system};
in
{
imports = [
"${inputs.nixpkgs-unstable}/nixos/modules/services/web-apps/readeck.nix"
];
options.services.readeck = {
subdomain = lib.mkOption {
type = lib.types.str;
};
};
config = lib.mkIf cfg.enable {
services.readeck = {
package = pkgsUnstable.readeck;
environmentFile = secrets.readeck.path;
settings = {
server.port = lib.mkDefault 8090;
};
};
modules.services.webserver = {
enable = lib.mkDefault true;
vHosts.${fqdn} = {
proxyBuffering = false;
locations."/" = {
proxyPort = cfg.settings.server.port;
};
};
};
};
}

BIN
secrets/readeck.age Normal file

Binary file not shown.

View File

@@ -16,4 +16,5 @@ in
"storage-box-credentials.age".publicKeys = users ++ [ freun-dev ];
"vaultwarden.age".publicKeys = users ++ [ freun-dev ];
"smtp-password.age".publicKeys = users ++ [ freun-dev ];
"readeck.age".publicKeys = users ++ [ freun-dev ];
}