diff --git a/modules/config/instances/config/podgrab.nix b/modules/config/instances/config/podgrab.nix deleted file mode 100755 index 3635de6..0000000 --- a/modules/config/instances/config/podgrab.nix +++ /dev/null @@ -1,35 +0,0 @@ -{ moduleFunctions }: -let - inherit (moduleFunctions.instancesFunctions) - domain0 - servicePath - sslPath - sopsPath - ; - - label = "Podgrab"; - name = "podgrab"; - subdomain = "podcasts"; - domain = "${subdomain}.${domain0}"; -in -{ - label = label; - name = name; - sops = { - path0 = "${sopsPath}/${name}"; - }; - domains = { - url0 = domain; - }; - subdomain = name; - paths = { - path0 = "${servicePath}/${label}"; - }; - ports = { - port0 = 4242; - }; - ssl = { - cert = "${sslPath}/${name}.${domain0}/fullchain.pem"; - key = "${sslPath}/${name}.${domain0}/key.pem"; - }; -} diff --git a/modules/nixos/services/acme/default.nix b/modules/nixos/services/acme/default.nix index 659eff6..1cbec44 100755 --- a/modules/nixos/services/acme/default.nix +++ b/modules/nixos/services/acme/default.nix @@ -38,7 +38,6 @@ in "nextcloud" "syncthing" "searx" - "podgrab" "vaultwarden" "audiobookshelf" ] diff --git a/modules/nixos/services/podgrab/default.nix b/modules/nixos/services/podgrab/default.nix deleted file mode 100755 index 82a5b95..0000000 --- a/modules/nixos/services/podgrab/default.nix +++ /dev/null @@ -1,77 +0,0 @@ -{ config, flake, ... }: -let - inherit (flake.config.services.instances) podgrab web; - inherit (flake.config.machines.devices) ceres; - service = podgrab; - localhost = web.localhost.address0; - host = service.domains.url0; -in -{ - services = { - podgrab = { - enable = true; - port = service.ports.port0; - passwordFile = config.sops.secrets."${service.name}-pass".path; - dataDirectory = service.paths.path0; - }; - caddy = { - virtualHosts = { - "${host}" = { - extraConfig = '' - redir /.well-known/carddav /remote.php/dav/ 301 - redir /.well-known/caldav /remote.php/dav/ 301 - - reverse_proxy ${localhost}:${toString service.ports.port0} - - tls ${service.ssl.cert} ${service.ssl.key} - ''; - }; - }; - }; - }; - - sops = - let - sopsPath = secret: { - path = "${service.sops.path0}/password.env"; - owner = service.name; - mode = "600"; - }; - in - { - secrets = builtins.listToAttrs ( - map - (secret: { - name = "${service.name}-${secret}"; - value = sopsPath secret; - }) - [ - "pass" - ] - ); - }; - - fileSystems."/var/lib/${service.name}" = { - device = service.paths.path0; - fsType = "none"; - options = [ - "bind" - ]; - depends = [ - ceres.storage0.mount - ]; - }; - - systemd.tmpfiles.rules = [ - "Z ${service.paths.path0} 0755 ${service.name} ${service.name} -" - "Z ${service.sops.path0} 0755 ${service.name} ${service.name} -" - ]; - - networking = { - firewall = { - allowedTCPPorts = [ - service.ports.port0 - ]; - }; - }; -}