mirror of
https://github.com/LnL7/nix-darwin.git
synced 2025-03-16 05:18:17 +00:00
services/nix-daemon: improve support for env vars
This commit is contained in:
parent
ec12b88104
commit
758f62d39d
1 changed files with 12 additions and 0 deletions
|
@ -20,6 +20,17 @@ in
|
||||||
description = "Whether to make the nix-daemon service socket activated.";
|
description = "Whether to make the nix-daemon service socket activated.";
|
||||||
};
|
};
|
||||||
|
|
||||||
|
services.nix-daemon.environmentVariables = mkOption {
|
||||||
|
type = types.attrsOf types.str;
|
||||||
|
default = { };
|
||||||
|
example = {
|
||||||
|
AWS_CONFIG_FILE = "/etc/nix/aws/config";
|
||||||
|
AWS_SHARED_CREDENTIALS_FILE = "/etc/nix/aws/credentials";
|
||||||
|
NIX_SSL_CERT_FILE = "/etc/nix/my-cert-file.crt";
|
||||||
|
};
|
||||||
|
description = "Extra environment variables provided to nix-daemon";
|
||||||
|
};
|
||||||
|
|
||||||
services.nix-daemon.logFile = mkOption {
|
services.nix-daemon.logFile = mkOption {
|
||||||
type = types.nullOr types.path;
|
type = types.nullOr types.path;
|
||||||
default = null;
|
default = null;
|
||||||
|
@ -62,6 +73,7 @@ in
|
||||||
};
|
};
|
||||||
|
|
||||||
serviceConfig.EnvironmentVariables = mkMerge [
|
serviceConfig.EnvironmentVariables = mkMerge [
|
||||||
|
cfg.environmentVariables
|
||||||
config.nix.envVars
|
config.nix.envVars
|
||||||
{
|
{
|
||||||
NIX_SSL_CERT_FILE = mkIf
|
NIX_SSL_CERT_FILE = mkIf
|
||||||
|
|
Loading…
Add table
Reference in a new issue