refactor: WARP

This commit is contained in:
Sergei Maklagin
2025-06-08 19:51:17 +03:00
parent 5c911c97d8
commit 4e74a4108d
12 changed files with 346 additions and 253 deletions

20
constant/warp.go Normal file
View File

@@ -0,0 +1,20 @@
package constant
type WARPConfig struct {
PrivateKey string `json:"private_key"`
Interface struct {
Addresses struct {
V4 string `json:"v4"`
V6 string `json:"v6"`
} `json:"addresses"`
} `json:"interface"`
Peers []struct {
PublicKey string `json:"public_key"`
Endpoint struct {
V4 string `json:"v4"`
V6 string `json:"v6"`
Host string `json:"host"`
Ports []int `json:"ports"`
} `json:"endpoint"`
} `json:"peers"`
}