From cbfa03e57c97f7afeabd5e095120bcd06a20bb85 Mon Sep 17 00:00:00 2001 From: =bhagwanSingh Date: Mon, 15 Dec 2025 13:44:59 +0530 Subject: [PATCH] wg0 permission issue --- src/vpnHandler/vpn.js | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/vpnHandler/vpn.js b/src/vpnHandler/vpn.js index 347f162..3c8efc3 100644 --- a/src/vpnHandler/vpn.js +++ b/src/vpnHandler/vpn.js @@ -51,7 +51,10 @@ AllowedIPs = 10.0.0.${ipLast}/32 fs.appendFileSync(WG_CONF, peerEntry); // apply config instantly - execSync(`wg syncconf wg0 <(wg-quick strip wg0)`, { shell: "/bin/bash" }); + // execSync(`wg syncconf wg0 <(wg-quick strip wg0)`, { shell: "/bin/bash" }); + execSync(`wg-quick strip wg0 > /tmp/wg0.tmp`); + execSync(`wg syncconf wg0 /tmp/wg0.tmp`); + } function generateClientConf(privateKey, ip) {