Merge pull request #179716 from domenkozar/cachix-agent-verbose

cachix-agent: expose verbose option
This commit is contained in:
Domen Kožar 2022-06-30 10:20:58 -05:00 committed by GitHub
commit be443e9adb
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -17,6 +17,12 @@ in {
defaultText = "config.networking.hostName";
};
verbose = mkOption {
type = types.bool;
description = "Enable verbose output";
default = false;
};
profile = mkOption {
type = types.nullOr types.str;
default = null;
@ -54,7 +60,7 @@ in {
serviceConfig = {
Restart = "on-failure";
EnvironmentFile = cfg.credentialsFile;
ExecStart = "${cfg.package}/bin/cachix deploy agent ${cfg.name} ${if cfg.profile != null then profile else ""}";
ExecStart = "${cfg.package}/bin/cachix ${lib.optionalString cfg.verbose "--verbose"} deploy agent ${cfg.name} ${if cfg.profile != null then profile else ""}";
};
};
};