support range ports mapping by go template (#4073)

This commit is contained in:
fatedier
2024-03-15 17:23:16 +08:00
committed by GitHub
parent 8383d528d9
commit 3585f5c0c0
10 changed files with 117 additions and 19 deletions

View File

@@ -1,11 +1,9 @@
package framework
type FRPClient struct {
port int
}
import (
clientsdk "github.com/fatedier/frp/pkg/sdk/client"
)
func (f *Framework) FRPClient(port int) *FRPClient {
return &FRPClient{
port: port,
}
func (f *Framework) APIClientForFrpc(port int) *clientsdk.Client {
return clientsdk.New("127.0.0.1", port)
}