From 306823c77e0f5cbd3958182503e79696cc9b4afb Mon Sep 17 00:00:00 2001 From: Amneesh Singh Date: Tue, 11 Nov 2025 22:36:36 +0530 Subject: [PATCH] hosts/suwako: prevent spam on gitea Signed-off-by: Amneesh Singh --- hosts/suwako/services/gitea.nix | 15 +++++++++++++-- 1 file changed, 13 insertions(+), 2 deletions(-) diff --git a/hosts/suwako/services/gitea.nix b/hosts/suwako/services/gitea.nix index e8016b3..d4d2c0e 100644 --- a/hosts/suwako/services/gitea.nix +++ b/hosts/suwako/services/gitea.nix @@ -1,7 +1,6 @@ { - config, - pkgs, conf, + lib, ... }: { @@ -36,6 +35,18 @@ USER = FROM; REGISTER_MAIL_CONFIRM = true; }; + service = { + ENABLE_CAPTCHA = true; + EMAIL_DOMAIN_ALLOWLIST = lib.strings.concatStringsSep "," [ + "gmail.com" + "outlook.com" + "proton.me" + "protonmail.com" + conf.network.addresses.domain.natto + conf.network.addresses.domain.amneesh + "chutiya.online" + ]; + }; oauth2_client.REGISTER_MAIL_CONFIRM = true; actions.ENABLED = false; };