From 88b230c46fb3a64ae0b19d64cbcd06f7943fc31c Mon Sep 17 00:00:00 2001 From: Jimbo Date: Wed, 11 Sep 2024 15:57:29 -0400 Subject: [PATCH] Add Pixelfed --- nixos/server.nix | 2 +- nixos/server/pixelfed.nix | 29 +++++++++++++++++++++++++++-- secrets.nix | Bin 2174 -> 2293 bytes 3 files changed, 28 insertions(+), 3 deletions(-) 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; + forceSS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