Add INIT_ALLOWED_IPS for unattended setup (#2164)

* Add INIT_ALLOWED_IPS env var

Implement INIT_ALLOWED_IPS env var like the INIT_DNS to preset the global Allowed IPs field.

* Docs: Add INIT_ALLOWED_IPS var to unattended setup table

* Make UserConfigService.update param partial

Update UserConfigService.update() to accept any subset of the updatable fields.
Remove the unnecessary userConfig object from  DBService.initialSetup()

* formatting fix

* format on linux

On windows prettier get confused by global conf... common windows things
This commit is contained in:
Németh Bálint
2025-09-16 12:16:31 +02:00
committed by GitHub
parent 8892c43a7d
commit 6c0d8e91fa
4 changed files with 21 additions and 14 deletions
+1
View File
@@ -38,6 +38,7 @@ export const WG_INITIAL_ENV = {
DNS: process.env.INIT_DNS?.split(',').map((x) => x.trim()),
IPV4_CIDR: process.env.INIT_IPV4_CIDR,
IPV6_CIDR: process.env.INIT_IPV6_CIDR,
ALLOWED_IPS: process.env.INIT_ALLOWED_IPS?.split(',').map((x) => x.trim()),
HOST: process.env.INIT_HOST,
PORT: process.env.INIT_PORT
? Number.parseInt(process.env.INIT_PORT, 10)