{ self, linux-hardened, ... }: { lib, config, pkgs, ... }: with lib; let ports = { acme = 1360; nginx = 8080; synapse = 8008; unbound = 8484; }; security-txt = pkgs.writeText "security.txt" '' -----BEGIN SSH SIGNED MESSAGE----- Canonical: https://solitary.social/.well-known/security.txt Contact: mailto:mvs@nya.yt Encryption: data:application/x-age-public-key,age1dexxdduwl37hsfdxde6le0satatrfv4geva0cxt8qqw3n46vgavsanuewp Preferred-Languages: en, de -----END SSH SIGNED MESSAGE----- -----BEGIN SSH SIGNATURE----- U1NIU0lHAAAAAQAAAEoAAAAac2stc3NoLWVkMjU1MTlAb3BlbnNzaC5jb20AAAAgJzM8dH Bj0wDAMaVwHRCAw4mNyksmFVTdyi+tb1EFLrYAAAAEc3NoOgAAAARmaWxlAAAAAAAAAAZz aGE1MTIAAABnAAAAGnNrLXNzaC1lZDI1NTE5QG9wZW5zc2guY29tAAAAQNoPCgqiDsNs8+ PyhjKdWF3P0TkA3gXH9fRSCRJvlMTz5hlhusz6ipEnKb8q/fYIwiuPsIJQseevg1kFZTe3 vAoBAAADlA== -----END SSH SIGNATURE----- ''; in { imports = with self.nixosModules; [ default headless acme-ocsp ]; boot.loader.grub = { enable = true; device = "/dev/vda"; }; boot.kernelParams = [ "hugepagesz=1G" "hugepages=1" ]; boot.kernelPackages = let inherit (linux-hardened.packages.x86_64-linux) paravirt; in pkgs.linuxPackagesFor (paravirt.override { instSetArch = "x86-64-v3"; extraConfig = with linux-hardened.lib.kernel; { NR_CPUS = 8; BTRFS_FS = true; BTRFS_FS_POSIX_ACL = true; CRYPTO_ZSTD = true; }; }); environment.etc."machine-id".text = "1c97ae368741530de77aad42b5a6ae42"; ephemeral.device = "UUID=07a91cc3-4dd4-48e6-81d7-eb5d31fcf720"; ephemeral.boot.device = "UUID=24c72e0c-b467-4def-a641-ae09100465f0"; ephemeral.boot.fsType = "ext4"; i18n.supportedLocales = [ "C.UTF-8/UTF-8" "en_EU.UTF-8/UTF-8" "en_GB.UTF-8/UTF-8" ]; networking = { hostName = "solitary"; domain = "social"; firewall.allowedTCPPorts = [ 22 80 443 853 ]; firewall.allowedUDPPorts = [ 443 ]; }; security.acme = { certs.${config.networking.fqdn} = { email = "mvs@nya.yt"; listenHTTP = "127.0.0.1:${toString ports.acme}"; reloadServices = [ "haproxy.service" "unbound.service" ]; extraDomainNames = [ "cache.solitary.social" "matrix.solitary.social" "media.solitary.social" "resolve.solitary.social" ]; }; }; services.akkoma.enable = true; services.akkoma.extraPackages = with pkgs; [ exiftool ffmpeg-headless imagemagick ]; services.akkoma.extraStatic."emoji/blobs.gg" = pkgs.akkoma-emoji.blobs_gg; services.akkoma.extraStatic."static/terms-of-service.html" = pkgs.writeText "terms-of-service.html" ''
This was originally a single‐user instance and therefore I decided to formulate what would be Terms of Service for a multi‐user user instance as commitments. These are still incomplete and subject to expansion in the future.