❄️ Dotfiles for our NixOS system configuration.
1{ config, lib, ... }: 2 3{ 4 age.secrets.bluesky-pds = { 5 file = ../../secrets/bluesky-pds.age; 6 owner = "pds"; 7 group = "pds"; 8 mode = "600"; 9 }; 10 11 services.bluesky-pds = { 12 enable = true; 13 pdsadmin.enable = true; 14 settings = { 15 PDS_HOSTNAME = "pds.sappho.systems"; 16 PDS_PORT = 3333; 17 PDS_CRAWLERS = lib.concatStringsSep "," [ 18 "https://bsky.network" 19 "https://relay.cerulea.blue" 20 "https://relay.upcloud.world" 21 "https://atproto.africa" 22 ]; 23 }; 24 environmentFiles = [ config.age.secrets.bluesky-pds.path ]; 25 }; 26 27 services.caddy.virtualHosts."pds.sappho.systems" = { 28 serverAliases = [ "*.pds.sappho.systems" ]; 29 extraConfig = '' 30 import common 31 import tls_cloudflare 32 33 handle / { 34 respond <<EOF 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 Welcome to Sapphic Angels' AT Protocol Personal Data Server (PDS) 64 65 API routes accessible at /xrpc/ 66 67 Website: https://sapphic.moe 68 AT Protocol: https://atproto.com 69 Self-host your own PDS: https://github.com/bluesky-social/pds 70 71 🌸 🐇 72 EOF 200 73 } 74 75 handle { 76 reverse_proxy http://127.0.0.1:3333 77 } 78 ''; 79 }; 80}