Added tppBind
This commit is contained in:
parent
7313c4af99
commit
f25815aa1b
4 changed files with 31 additions and 12 deletions
18
flake.nix
18
flake.nix
|
|
@ -5,7 +5,7 @@
|
|||
nixpkgs.url = "github:nixos/nixpkgs?ref=nixos-unstable";
|
||||
flake-parts.url = "github:hercules-ci/flake-parts";
|
||||
ttp = {
|
||||
url = "git+https://git.methanium.net/Tensamin/TTP.git?rev=929cb9d3a6aebebe6365973f13062ac2a8e03af6";
|
||||
url = "git+https://git.methanium.net/Tensamin/TTP.git?rev=7e5d1953df8592a1feba0f390d205d0ef61a3119";
|
||||
flake = false;
|
||||
};
|
||||
};
|
||||
|
|
@ -98,6 +98,18 @@
|
|||
description = "Whether to open the firewall for ports used by Iota.";
|
||||
};
|
||||
|
||||
ttpBind = lib.mkOption {
|
||||
type = lib.types.str;
|
||||
default = "0.0.0.0";
|
||||
description = "IP address to bind the TTP/QUIC server to.";
|
||||
};
|
||||
|
||||
bindAddress = lib.mkOption {
|
||||
type = lib.types.str;
|
||||
default = "0.0.0.0";
|
||||
description = "IP address to bind the HTTP server to.";
|
||||
};
|
||||
|
||||
package = lib.mkOption {
|
||||
type = lib.types.package;
|
||||
default = defaultPackage;
|
||||
|
|
@ -190,6 +202,10 @@
|
|||
RestrictSUIDSGID = true;
|
||||
LockPersonality = true;
|
||||
MemoryDenyWriteExecute = true;
|
||||
Environment = [
|
||||
"TTP_BIND=${cfg.ttpBind}"
|
||||
"BIND_ADDRESS=${cfg.bindAddress}"
|
||||
];
|
||||
} // lib.optionalAttrs (cfg.environmentFiles != [ ]) {
|
||||
EnvironmentFile = cfg.environmentFiles;
|
||||
};
|
||||
|
|
|
|||
Loading…
Reference in a new issue