mirror of
https://github.com/NixOS/nixpkgs.git
synced 2026-07-06 17:13:24 -05:00
nixos/netbox: add gunicornArgs
configurable cli args for gunicorn
This commit is contained in:
parent
ed5cf6df1c
commit
c9365b4998
1 changed files with 12 additions and 1 deletions
|
|
@ -106,6 +106,16 @@ in
|
|||
example = "/run/netbox/netbox.sock";
|
||||
};
|
||||
|
||||
gunicornArgs = lib.mkOption {
|
||||
type = lib.types.listOf lib.types.str;
|
||||
default = [ ];
|
||||
description = "extra args for gunicorn when serving netbox";
|
||||
example = [
|
||||
"--workers"
|
||||
"9"
|
||||
];
|
||||
};
|
||||
|
||||
package = lib.mkOption {
|
||||
type = lib.types.package;
|
||||
default =
|
||||
|
|
@ -362,7 +372,8 @@ in
|
|||
else
|
||||
"${cfg.listenAddress}:${toString cfg.port}"
|
||||
} \
|
||||
--pythonpath ${pkg}/opt/netbox/netbox
|
||||
--pythonpath ${pkg}/opt/netbox/netbox \
|
||||
${lib.concatStringsSep " " cfg.gunicornArgs}
|
||||
'';
|
||||
PrivateTmp = true;
|
||||
TimeoutStartSec = lib.mkDefault "5min";
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue