mirror of
https://github.com/WeeJeWel/wg-easy.git
synced 2024-11-17 16:09:23 +08:00
chmod config files
This commit is contained in:
parent
3e473d0f81
commit
0d908f56a0
@ -99,8 +99,12 @@ AllowedIPs = ${client.address}/32`;
|
||||
}
|
||||
|
||||
debug('Saving config...');
|
||||
await fs.writeFile(path.join(WG_PATH, 'wg0.json'), JSON.stringify(config, false, 2));
|
||||
await fs.writeFile(path.join(WG_PATH, 'wg0.conf'), result);
|
||||
await fs.writeFile(path.join(WG_PATH, 'wg0.json'), JSON.stringify(config, false, 2), {
|
||||
mode: 0o660,
|
||||
});
|
||||
await fs.writeFile(path.join(WG_PATH, 'wg0.conf'), result, {
|
||||
mode: 0o600,
|
||||
});
|
||||
debug('Config saved.');
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user