diff --git a/dragonwell/caddy.nix b/dragonwell/caddy.nix index 3f36e5dcbbe5daf33f90a423cc2c3f5862fc07ca..0c33111ab09f72db12947314284b87445ef0f808 100644 --- a/dragonwell/caddy.nix +++ b/dragonwell/caddy.nix @@ -80,32 +80,6 @@ ''; "memos.jolheiser.com".extraConfig = '' reverse_proxy localhost:6366 ''; - "oa2p.jolheiser.com".extraConfig = '' - reverse_proxy localhost:6227 - ''; - "wiki.jolheiser.com".extraConfig = '' - handle /oauth2/* { - reverse_proxy localhost:6227 { - header_up X-Real-IP {remote_host} - header_up X-Forwarded-Uri {uri} - } - } - - handle { - forward_auth localhost:6227 { - uri /oauth2/auth - - header_up X-Real-IP {remote_host} - - @error status 401 - handle_response @error { - redir * /oauth2/sign_in?rd={scheme}://{host}{uri} - } - } - - reverse_proxy localhost:9454 - } - ''; "budget.jolheiser.com".extraConfig = '' handle_path /static/* { root * ${pkgs.jolheiser.mint}/lib/mint/static/ diff --git a/dragonwell/default.nix b/dragonwell/default.nix index 92b754277fdd5a5c1213a7e94c51f96a3502efd1..1c3ea962f0bca67f05cc1105df49a85652c64e7e 100644 --- a/dragonwell/default.nix +++ b/dragonwell/default.nix @@ -11,13 +11,11 @@ ./forge-lines.nix ./foundry.nix #./git-bug.nix ./git-pr.nix - ./gollum.nix ./horcrux.nix ./mealie.nix ./memos.nix ./miniserve.nix ./mint.nix - ./oa2p.nix ./pocket-id.nix ./pubserve.nix ./restic.nix diff --git a/dragonwell/gollum.nix b/dragonwell/gollum.nix deleted file mode 100644 index 0cb4a5099f7b66a6b6408c5cbabbd66f3852ccf9..0000000000000000000000000000000000000000 --- a/dragonwell/gollum.nix +++ /dev/null @@ -1,39 +0,0 @@ -{ pkgs, config, ... }: -{ - services.gollum = { - enable = true; - stateDir = "/var/lib/ugit/repos/wiki.git"; - emoji = true; - h1-title = true; - port = 9454; - branch = "main"; - user = "ugit"; - group = "ugit"; - }; - - # Hack to work with bare repos - systemd.services.gollum = - let - cfg = config.services.gollum; - in - { - preStart = pkgs.lib.mkForce '' - git init --bare ${cfg.stateDir} - ''; - serviceConfig.ExecStart = pkgs.lib.mkForce '' - ${cfg.package}/bin/gollum \ - --port ${toString cfg.port} \ - --host ${cfg.address} \ - --config ${pkgs.writeText "gollum-config.rb" cfg.extraConfig} \ - --ref ${cfg.branch} \ - ${pkgs.lib.optionalString cfg.math "--math"} \ - ${pkgs.lib.optionalString cfg.emoji "--emoji"} \ - ${pkgs.lib.optionalString cfg.h1-title "--h1-title"} \ - ${pkgs.lib.optionalString cfg.no-edit "--no-edit"} \ - ${pkgs.lib.optionalString (cfg.allowUploads != null) "--allow-uploads ${cfg.allowUploads}"} \ - ${pkgs.lib.optionalString (cfg.user-icons != null) "--user-icons ${cfg.user-icons}"} \ - --bare \ - ${cfg.stateDir} - ''; - }; -} diff --git a/dragonwell/oa2p.nix b/dragonwell/oa2p.nix deleted file mode 100644 index 08b18722d34b5afa7e42043e63bd972e38f7b99f..0000000000000000000000000000000000000000 --- a/dragonwell/oa2p.nix +++ /dev/null @@ -1,18 +0,0 @@ -{ config, ... }: -{ - age.secrets.oa2p.file = ../secrets/oa2p.age; - services.oauth2-proxy = { - enable = true; - provider = "oidc"; - httpAddress = "localhost:6227"; - reverseProxy = true; - cookie = { - secure = true; - domain = "wiki.jolheiser.com"; - }; - email.domains = [ "*" ]; - keyFile = config.age.secrets.oa2p.path; - redirectURL = "https://wiki.jolheiser.com/oauth2/callback"; - oidcIssuerUrl = "https://id.jolheiser.com"; - }; -} diff --git a/secrets/oa2p.age b/secrets/oa2p.age deleted file mode 100644 index afa7b429d438c4a27797d98816ab7b6ccaaad790..0000000000000000000000000000000000000000 Binary files a/secrets/oa2p.age and /dev/null differ diff --git a/secrets/secrets.nix b/secrets/secrets.nix index ca90266465f13a5d9bb57209ec60f78ebffe6f09..354ead0d1c8d2df1cf51935d29b2be6df06e4808 100644 --- a/secrets/secrets.nix +++ b/secrets/secrets.nix @@ -44,5 +44,4 @@ "horcrux.age".publicKeys = dragonwellKeys; "mint.age".publicKeys = dragonwellKeys; "cifs.age".publicKeys = jasmineKeys; "beanboy.age".publicKeys = peachKeys; - "oa2p.age".publicKeys = dragonwellKeys; }