This commit is contained in:
parent
d942de22de
commit
42b4334d07
@ -129,7 +129,7 @@ func (clients) Download(c *gin.Context) {
|
||||
|
||||
// 处理一下数据
|
||||
execData := template_data.ClientConfig{
|
||||
PrivateKey: keys.PrivateKey,
|
||||
PrivateKey: data.Server.PrivateKey,
|
||||
IpAllocation: data.IpAllocation,
|
||||
MTU: setting.MTU,
|
||||
DNS: strings.Join(setting.DnsServer, ","),
|
||||
@ -201,7 +201,7 @@ func (clients) GenerateQrCode(c *gin.Context) {
|
||||
|
||||
// 处理一下数据
|
||||
execData := template_data.ClientConfig{
|
||||
PrivateKey: keys.PrivateKey,
|
||||
PrivateKey: data.Server.PrivateKey,
|
||||
IpAllocation: data.IpAllocation,
|
||||
MTU: setting.MTU,
|
||||
PublicKey: keys.PublicKey,
|
||||
|
@ -4,6 +4,8 @@ type SaveServer struct {
|
||||
Id string `json:"id" form:"id" binding:"omitempty"` // id
|
||||
IpScope string `json:"ipScope" form:"ipScope" binding:"required"` // 内网ip范围段
|
||||
ListenPort int `json:"listenPort" form:"listenPort" binding:"required"` // 监听端口
|
||||
PrivateKey string `json:"privateKey" form:"privateKey"` // 私钥
|
||||
PublicKey string `json:"publicKey" form:"publicKey"` // 密钥
|
||||
PostUpScript string `json:"postUpScript" form:"postUpScript" binding:"omitempty"`
|
||||
PreDownScript string `json:"preDownScript" form:"preDownScript" binding:"omitempty"`
|
||||
PostDownScript string `json:"postDownScript" form:"postDownScript" binding:"omitempty"`
|
||||
|
Loading…
Reference in New Issue
Block a user