Browse Source

load allowedIPs from wireguard show wg0 dump in WireGuard service

pull/82/head
Vojta Drbohlav 4 years ago
parent
commit
103e0ff679
  1. 5
      src/lib/WireGuard.js

5
src/lib/WireGuard.js

@ -120,12 +120,12 @@ AllowedIPs = ${client.address}/32`;
publicKey: client.publicKey,
createdAt: new Date(client.createdAt),
updatedAt: new Date(client.updatedAt),
allowedIPs: client.allowedIPs,
persistentKeepalive: null,
latestHandshakeAt: null,
transferRx: null,
transferTx: null,
allowedIPs: null,
}));
// Loop WireGuard status
@ -141,7 +141,7 @@ AllowedIPs = ${client.address}/32`;
publicKey,
preSharedKey, // eslint-disable-line no-unused-vars
endpoint, // eslint-disable-line no-unused-vars
allowedIps, // eslint-disable-line no-unused-vars
allowedIPs,
latestHandshakeAt,
transferRx,
transferTx,
@ -157,6 +157,7 @@ AllowedIPs = ${client.address}/32`;
client.transferRx = Number(transferRx);
client.transferTx = Number(transferTx);
client.persistentKeepalive = persistentKeepalive;
client.allowedIPs = allowedIPs;
});
return clients;

Loading…
Cancel
Save