feat(services/forgejo): configure mailer with sendgrid
This commit is contained in:
parent
5c816c5b0a
commit
785cf77e89
@ -61,6 +61,11 @@ in {
|
||||
|
||||
config = mkMerge [
|
||||
(mkIf cfg.enable {
|
||||
age.secrets.forgejoSendgridKey = {
|
||||
file = ../../../secrets/sendgrid-key.age;
|
||||
owner = "forgejo";
|
||||
group = "forgejo";
|
||||
};
|
||||
services.forgejo = {
|
||||
enable = true;
|
||||
package = pkgs.unstable.forgejo;
|
||||
@ -83,6 +88,15 @@ in {
|
||||
settings.oauth2_client = {
|
||||
ENABLE_AUTO_REGISTRATION = true;
|
||||
};
|
||||
settings.mailer = {
|
||||
ENABLED = true;
|
||||
FROM = "forgejo@michaelt.xyz";
|
||||
PROTOCOL = "starttls";
|
||||
SMTP_ADDR = "smtp.sendgrid.net";
|
||||
SMTP_PORT = 587;
|
||||
USER = "apikey";
|
||||
};
|
||||
mailerPasswordFile = config.age.secrets.forgejoSendgridKey.path;
|
||||
};
|
||||
|
||||
networking.firewall.interfaces."${firewallInterface}".allowedTCPPorts = [cfg.port];
|
||||
|
@ -7,6 +7,7 @@ in {
|
||||
"wireguard-thinkcentre.age".publicKeys = [venus];
|
||||
"keycloak-db.age".publicKeys = [venus];
|
||||
"forgejo-actions.age".publicKeys = [venus];
|
||||
"sendgrid-key.age".publicKeys = [venus];
|
||||
|
||||
# Oracle
|
||||
"wireguard-oracle.age".publicKeys = [oracle];
|
||||
|
BIN
secrets/sendgrid-key.age
Normal file
BIN
secrets/sendgrid-key.age
Normal file
Binary file not shown.
Loading…
x
Reference in New Issue
Block a user