dynix/modules/dynamicism/gotosocial.nix

21 lines
587 B
Nix
Raw Normal View History

2026-02-10 14:19:55 +01:00
{ pkgs, lib, config, ... }:
let
settingsFormat = pkgs.formats.yaml { };
2026-02-10 14:59:44 +01:00
configFile = settingsFormat.generate "gotosocial-override.yml" config.services.gotosocial.settings;
2026-02-10 14:19:55 +01:00
in
{
dynamicism.for.gotosocial = {
source-options = [ "services.gotosocial.settings" ];
2026-02-10 14:59:44 +01:00
unitDropins."gotosocial.service" = pkgs.writeTextFile {
name = "gotosocial-override.conf";
text = ''
[Service]
ExecStart=
ExecStart=${lib.getExe' pkgs.gotosocial "gotosocial"} --config-path ${configFile} start
'';
passthru = { inherit configFile; };
};
2026-02-10 14:19:55 +01:00
};
}