mirror of
https://github.com/oqyude/nixos.git
synced 2026-10-07 20:47:14 +03:00
restructuring
This commit is contained in:
@@ -35,35 +35,9 @@ let
|
||||
realityPorts = lib.optional config.host."3x-ui".reality443Forwarding "127.0.0.1:15380:443/tcp";
|
||||
in
|
||||
{
|
||||
options.host."3x-ui" = {
|
||||
# Domain whose LE cert should be mounted into the 3x-ui container at
|
||||
# /root/cert/fullchain.pem and key.pem. Set null if 3x-ui serves plain
|
||||
# HTTP and TLS is terminated by an upstream nginx.
|
||||
certDomain = lib.mkOption {
|
||||
type = lib.types.nullOr lib.types.str;
|
||||
default = null;
|
||||
example = "pubray1.zeroq.su";
|
||||
description = ''
|
||||
Domain whose LE cert should be mounted into the 3x-ui
|
||||
container at /root/cert/fullchain.pem and key.pem.
|
||||
'';
|
||||
};
|
||||
# Publish host:15380 → container:443. Only nodes that host an Xray
|
||||
# REALITY inbound on container:443 need this (so nginx stream can
|
||||
# forward TLS to Xray via 127.0.0.1:15380 while Xray itself sees
|
||||
# incoming connections on its configured port 443). Set false on nodes
|
||||
# that only run the 3x-ui panel.
|
||||
reality443Forwarding = lib.mkOption {
|
||||
type = lib.types.bool;
|
||||
default = false;
|
||||
description = ''
|
||||
When true, publish host:15380 → container:443 so Xray
|
||||
inside the container can serve REALITY on its real
|
||||
configured port 443 (nginx stream forwards 443 → 15380).
|
||||
'';
|
||||
};
|
||||
};
|
||||
|
||||
# `host."3x-ui"` options are declared in modules/options.nix: they are set
|
||||
# by modules/server and modules/vds, so this module cannot be the only place
|
||||
# that knows they exist.
|
||||
config = {
|
||||
virtualisation = {
|
||||
podman = {
|
||||
|
||||
Reference in New Issue
Block a user