Add client DNS config when client allows all IPs
This commit is contained in:
@@ -125,7 +125,9 @@ export default async function setupWireguardClient({
|
||||
sh += `[Interface]\n`;
|
||||
sh += `Address = ${CLIENT_WG_IP}/32\n`;
|
||||
sh += `PrivateKey = ${CLIENT_PRIVATE_KEY}\n`;
|
||||
// sh += `DNS = 1.1.1.1\n`;
|
||||
if (client?.allow_all_ips == 1) {
|
||||
sh += `DNS = 1.1.1.1\n`;
|
||||
}
|
||||
sh += `\n`;
|
||||
sh += `[Peer]\n`;
|
||||
sh += `PublicKey = ${HOST_PUBLIC_KEY}\n`;
|
||||
|
||||
Reference in New Issue
Block a user