HeshamTB
8e798706e3
Creates a new peer server-side. - Gen keys - Allocate IP - Add to WG Link - Respond with a read wg config for the client to use
13 lines
320 B
Cheetah
13 lines
320 B
Cheetah
[Interface]
|
|
Address = {{ .Address }}/24
|
|
PrivateKey = {{ .PrivateKey }}
|
|
DNS = {{$dnss := .DNS}}{{range $index, $element := .DNS}}{{if $index}}, {{end}}{{$element.String}}{{end}}
|
|
MTU = {{ .MTU }}
|
|
|
|
[Peer]
|
|
PublicKey = {{ .Peer.PublicKey }}
|
|
Endpoint = {{ .Endpoint }}
|
|
AllowedIPs = 0.0.0.0/0, ::0/0
|
|
PersistentKeepalive = 25
|
|
|