tests.basic -> tests.gotosocial
This commit is contained in:
parent
68e9b9a1e4
commit
1f466b63d3
9 changed files with 23 additions and 16 deletions
|
|
@ -120,19 +120,7 @@ in
|
|||
);
|
||||
|
||||
# Implementations.
|
||||
config.dynamicism.for.gotosocial = let
|
||||
cfg = config.dynamicism.for.gotosocial;
|
||||
in {
|
||||
source-options = [
|
||||
"services.gotosocial.settings"
|
||||
];
|
||||
|
||||
configFile = settingsFormat.generate "gotosocial-override.yml" config.services.gotosocial.settings;
|
||||
|
||||
unitDropins."gotosocial.service" = pkgs.writeText "gotosocial-override.conf" ''
|
||||
[Service]
|
||||
ExecStart=
|
||||
ExecStart=${lib.getExe' pkgs.gotosocial "gotosocial"} --config-path ${cfg.configFile} start
|
||||
'';
|
||||
};
|
||||
imports = [
|
||||
./gotosocial.nix
|
||||
];
|
||||
}
|
||||
|
|
|
|||
19
modules/dynamicism/gotosocial.nix
Normal file
19
modules/dynamicism/gotosocial.nix
Normal file
|
|
@ -0,0 +1,19 @@
|
|||
{ pkgs, lib, config, ... }:
|
||||
let
|
||||
cfg = config.dynamicism.for.gotosocial;
|
||||
|
||||
settingsFormat = pkgs.formats.yaml { };
|
||||
in
|
||||
{
|
||||
dynamicism.for.gotosocial = {
|
||||
source-options = [ "services.gotosocial.settings" ];
|
||||
|
||||
configFile = settingsFormat.generate "gotosocial-overrde.yml" config.services.gotosocial.settings;
|
||||
|
||||
unitDropins."gotosocial.service" = pkgs.writeText "gotosocial-override.conf" ''
|
||||
[Service]
|
||||
ExecStart=
|
||||
ExecStart=${lib.getExe' pkgs.gotosocial "gotosocial"} --config-path ${cfg.configFile} start
|
||||
'';
|
||||
};
|
||||
}
|
||||
|
|
@ -27,5 +27,5 @@
|
|||
};
|
||||
|
||||
in lib.makeScope lib.callPackageWith (self: {
|
||||
basic = runDynixTest ./basic/test.nix;
|
||||
gotosocial = runDynixTest ./gotosocial/test.nix;
|
||||
})
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue