Apply inbounds on nodes via Xray with Reality settings and client sync.
Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
@@ -7,7 +7,7 @@ import (
|
||||
"github.com/orohi/vpn-panel/internal/models"
|
||||
)
|
||||
|
||||
const AgentVersion = "0.1.0"
|
||||
const AgentVersion = "0.2.0"
|
||||
|
||||
func ComposeYAML(n *models.Node) string {
|
||||
return fmt.Sprintf(`services:
|
||||
@@ -21,10 +21,13 @@ func ComposeYAML(n *models.Node) string {
|
||||
NODE_PORT: %q
|
||||
SECRET_KEY: %q
|
||||
AGENT_VERSION: %q
|
||||
DATA_DIR: /var/lib/vpn-node
|
||||
HOST_DATA_DIR: /opt/vpn-panel-node/data
|
||||
volumes:
|
||||
- ./vpn-node:/usr/local/bin/vpn-node:ro
|
||||
- ./data:/var/lib/vpn-node
|
||||
command: ["/usr/local/bin/vpn-node"]
|
||||
- /var/run/docker.sock:/var/run/docker.sock
|
||||
command: ["sh", "-c", "apk add --no-cache docker-cli >/dev/null && exec /usr/local/bin/vpn-node"]
|
||||
`, n.Name, fmt.Sprintf("%d", n.NodePort), n.SecretKey, AgentVersion)
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user