mirror of https://git.jolheiser.com/ugit.git
chore: use yaml generator for flake
Signed-off-by: jolheiser <john.olheiser@gmail.com>ffdhall
parent
868ca2125a
commit
38c0c9c54b
|
@ -58,7 +58,8 @@
|
||||||
...
|
...
|
||||||
}: let
|
}: let
|
||||||
cfg = config.services.ugit;
|
cfg = config.services.ugit;
|
||||||
configFile = pkgs.writeText "ugit.yaml" cfg.configFile;
|
yamlFormat = pkgs.formats.yaml {};
|
||||||
|
configFile = pkgs.writeText "ugit.yaml" (builtins.readFile (yamlFormat.generate "ugit-yaml" cfg.config));
|
||||||
authorizedKeysFile = pkgs.writeText "ugit_keys" (builtins.concatStringsSep "\n" cfg.authorizedKeys);
|
authorizedKeysFile = pkgs.writeText "ugit_keys" (builtins.concatStringsSep "\n" cfg.authorizedKeys);
|
||||||
in {
|
in {
|
||||||
options = with lib; {
|
options = with lib; {
|
||||||
|
@ -95,9 +96,9 @@
|
||||||
default = "/var/lib/ugit/ugit_ed25519";
|
default = "/var/lib/ugit/ugit_ed25519";
|
||||||
};
|
};
|
||||||
|
|
||||||
configFile = mkOption {
|
config = mkOption {
|
||||||
type = types.str;
|
type = types.attrs;
|
||||||
default = "";
|
default = {};
|
||||||
description = "config.yaml contents";
|
description = "config.yaml contents";
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue