docs: improve the wording, add targeted examples
This commit is contained in:
61 files changed
+3422
-5861
No files matched your search
@@ -13,46 +13,46 @@ let
|
||||
in
|
||||
{
|
||||
options.services.proxy-suite.inbounds = {
|
||||
enable = mkEnableOption "server inbounds that accept proxy connections from outside";
|
||||
enable = mkEnableOption "server inbounds, which accept proxy clients from outside";
|
||||
|
||||
package = mkOption {
|
||||
type = types.package;
|
||||
default = proxySuiteUpstream.xray;
|
||||
defaultText = literalMD "proxy-suite's `xray` (`pkgs/xray.nix`)";
|
||||
example = literalExpression "pkgs.xray";
|
||||
description = "XRay package serving the inbounds, whatever the client-side backend.";
|
||||
description = "XRay package that runs the inbounds, whichever client backend is used.";
|
||||
};
|
||||
|
||||
serverAddress = mkOption {
|
||||
type = types.nullOr (types.strMatching "[^[:space:]]+");
|
||||
default = null;
|
||||
description = "Public address clients connect to, used in share links. Null detects the uplink IPv4.";
|
||||
description = "Public address for share links. `null`: detect the uplink IPv4.";
|
||||
example = "vpn.example.com";
|
||||
};
|
||||
|
||||
openFirewall = bool true "Open every non-loopback listener port.";
|
||||
shareLinks = bool true "Write client share links for `proxy-ctl inbounds link` (root, and userControl.group with the secrets scope).";
|
||||
openFirewall = bool true "Open the firewall for every listener not on loopback.";
|
||||
shareLinks = bool true "Generate client share links for `proxy-ctl inbounds link`. Readable by root, and by `userControl.group` with the secrets scope.";
|
||||
|
||||
subscriptions = {
|
||||
enable = mkEnableOption "" // {
|
||||
description = ''
|
||||
Write one subscription file per user (their links from every listener, base64) to
|
||||
/run/proxy-suite-inbounds/subscriptions/<token>. Serve that directory with a web server;
|
||||
see the README.
|
||||
Generate a subscription per user, with their links from every listener, in
|
||||
/run/proxy-suite-inbounds/subscriptions/<token>. Serve that directory with a web server.
|
||||
Needs `shareLinks`.
|
||||
'';
|
||||
};
|
||||
|
||||
group = mkOption {
|
||||
type = types.str;
|
||||
default = "nginx";
|
||||
description = "Group allowed to read the subscription files: the web server serving them.";
|
||||
description = "Group of the web server that serves the subscription files.";
|
||||
example = "caddy";
|
||||
};
|
||||
|
||||
baseUrl = mkOption {
|
||||
type = types.nullOr types.str;
|
||||
default = null;
|
||||
description = "URL the subscription directory is served at, for `proxy-ctl inbounds sub`.";
|
||||
description = "Public URL of the subscription directory, used by `proxy-ctl inbounds sub`.";
|
||||
example = "https://vpn.example.com/sub";
|
||||
};
|
||||
};
|
||||
@@ -63,27 +63,27 @@ in
|
||||
type = types.str;
|
||||
default = "proxy";
|
||||
description = ''
|
||||
Default egress of inbound traffic; listeners can override it:
|
||||
- "proxy": through the local proxy and its current selection (needs proxy.enable).
|
||||
- a proxy.outbounds tag: pinned to that server (url, urlFile or xrayJson outbounds only).
|
||||
- "direct": out from this machine.
|
||||
Where client traffic exits by default. Each listener can override it.
|
||||
- "proxy": through the local proxy and its current pick (needs `proxy.enable`).
|
||||
- an outbound tag from `proxy.outbounds`: always that one (`url`, `urlFile` or `xrayJson` only).
|
||||
- "direct": straight from this host.
|
||||
- "block": dropped.
|
||||
'';
|
||||
example = "direct";
|
||||
};
|
||||
|
||||
proxy = t.routingFields;
|
||||
proxy = t.routingFields "that clients always reach through the local proxy, whatever the listener's `via`";
|
||||
|
||||
blockRu = bool true ''Block Russian destinations (geosite "category-ru", geoip "ru").'';
|
||||
blockPrivate = bool true "Block private and loopback destinations, so clients cannot reach this host's LAN or local services.";
|
||||
blockPrivate = bool true "Block private and loopback addresses, so clients cannot reach this host's LAN or local services.";
|
||||
|
||||
zapretDirect = bool true "Send zapret's hostlist destinations direct, so this host's zapret unblocks them (default via only).";
|
||||
zapretDirect = bool true "Send zapret hostlist sites direct, so this host's zapret unblocks them. Only for the default `via`.";
|
||||
};
|
||||
|
||||
listeners = mkOption {
|
||||
type = types.attrsOf t.inboundType;
|
||||
default = { };
|
||||
description = "Listeners by tag.";
|
||||
description = "Server listeners, by tag.";
|
||||
example = literalExpression ''
|
||||
{
|
||||
vless-reality = {
|
||||
|
||||
Reference in new issue
Block a user