infrastructure/machines/compute01/mastodon.nix
Tom Hubrecht 4716f8a398
All checks were successful
build configuration / build_compute01 (push) Successful in 1m6s
build configuration / build_storage01 (push) Successful in 44s
build configuration / build_web01 (push) Successful in 57s
npins update / npins_update (push) Successful in 46s
feat(modules): Replace dgn-secrets by age-secrets
2024-01-09 14:48:33 +01:00

42 lines
912 B
Nix

{ config, ... }:
let host = "social.dgnum.eu";
in {
services.mastodon = {
enable = true;
localDomain = host;
smtp = {
# TODO: smtp setup
fromAddress = "social@services.dgnum.eu";
};
streamingProcesses = 4;
configureNginx = true;
extraConfig = {
# https://docs.codeberg.org/codeberg-pages/redirects/ is not yet active
# LOCAL_DOMAIN = "dgnum.eu";
WEB_DOMAIN = host;
RAILS_LOG_LEVEL = "warn";
# ObjectStorage configuration
S3_ENABLED = "true";
S3_BUCKET = "mastodon-dgnum";
S3_REGION = "garage";
S3_HOSTNAME = "s3.dgnum.eu";
S3_ALIAS_HOST = "cdn.dgnum.eu";
# TODO: Setup SAML & OIDC
# OIDC_ENABLED = true;
# SAML_ENABLED = true;
};
extraEnvFiles = [ config.age.secrets."mastodon-extra_env_file".path ];
};
age-secrets.matches."^mastodon-.*$" = { owner = "mastodon"; };
}