nixos/nginx: allow to specify which package to use
This enables to override which plugins to include with nginx by allowing to change nginx package. I also removed webdav option in nginx nixos module, because you can now specify this by overriding nginx package.
This commit is contained in:
parent
3c3c631a45
commit
c7429711b8
@ -4,7 +4,7 @@ with pkgs.lib;
|
|||||||
|
|
||||||
let
|
let
|
||||||
cfg = config.services.nginx;
|
cfg = config.services.nginx;
|
||||||
nginx = pkgs.nginx.override { fullWebDAV = cfg.fullWebDAV; };
|
nginx = cfg.package;
|
||||||
configFile = pkgs.writeText "nginx.conf" ''
|
configFile = pkgs.writeText "nginx.conf" ''
|
||||||
user ${cfg.user} ${cfg.group};
|
user ${cfg.user} ${cfg.group};
|
||||||
daemon off;
|
daemon off;
|
||||||
@ -22,6 +22,13 @@ in
|
|||||||
";
|
";
|
||||||
};
|
};
|
||||||
|
|
||||||
|
package = mkOption {
|
||||||
|
default = pkgs.nginx;
|
||||||
|
description = "
|
||||||
|
Nginx package to use.
|
||||||
|
";
|
||||||
|
};
|
||||||
|
|
||||||
config = mkOption {
|
config = mkOption {
|
||||||
default = "events {}";
|
default = "events {}";
|
||||||
description = "
|
description = "
|
||||||
@ -46,10 +53,6 @@ in
|
|||||||
description = "Group account under which nginx runs.";
|
description = "Group account under which nginx runs.";
|
||||||
};
|
};
|
||||||
|
|
||||||
fullWebDAV = mkOption {
|
|
||||||
default = false;
|
|
||||||
description = "Compile in a third party module providing full WebDAV support";
|
|
||||||
};
|
|
||||||
};
|
};
|
||||||
|
|
||||||
};
|
};
|
||||||
|
Loading…
x
Reference in New Issue
Block a user