diff --git a/nixos/server.nix b/nixos/server.nix index da5d15f..84f7fc9 100644 --- a/nixos/server.nix +++ b/nixos/server.nix @@ -50,7 +50,7 @@ # Federation ./server/lemmy.nix ./server/mastodon.nix - #./server/pixelfed.nix + ./server/pixelfed.nix ]; # Set custom openssh port diff --git a/nixos/server/pixelfed.nix b/nixos/server/pixelfed.nix index e213647..44f77d3 100644 --- a/nixos/server/pixelfed.nix +++ b/nixos/server/pixelfed.nix @@ -1,6 +1,31 @@ -{outputs, ...}: { +{pkgs, outputs, ...}: { services.pixelfed = { enable = true; - domain = "pixelfed.${outputs.secrets.jimDomain}"; + domain = "pics.${outputs.secrets.jimDomain}"; + secretFile = pkgs.writeText "appkey" outputs.secrets.pixelfedKey; + settings = { + APP_NAME = "Jimbofed"; + INSTANCE_DESCRIPTION = ''"The Jimbosfiles Pixelfed Instance"''; + INSTANCE_CONTACT_EMAIL = "jimbo@${outputs.secrets.jimDomain}"; + OPEN_REGISTRATION = true; + APP_LOCALE = "en"; + INSTANCE_DISCOVER_PUBLIC = false; + STORIES_ENABLED = true; + + # Mail config + ENFORCE_EMAIL_VERIFICATION = true; + MAIL_FROM_ADDRESS = "noreply@${outputs.secrets.jimDomain}"; + MAIL_FROM_NAME = ''"Jimbo's Pixelfed "''; + MAIL_ENCRYPTION = "tls"; + MAIL_DRIVER = "smtp"; + MAIL_HOST = "mx.${outputs.secrets.jimDomain}"; + MAIL_PORT = 587; + MAIL_USERNAME = "noreply@${outputs.secrets.jimDomain}"; + MAIL_PASSWORD = "${outputs.secrets.noreplyPassword}"; + }; + nginx = { + enableACME = true; + forceSSL = true; + }; }; } diff --git a/secrets.nix b/secrets.nix index b2f7f35..ce61c5b 100644 Binary files a/secrets.nix and b/secrets.nix differ