cmd/httpagent: customize frontend address

This commit is contained in:
Cadey Ratio 2017-01-22 09:48:37 -08:00
parent e350d53954
commit 69830acffb
1 changed files with 4 additions and 3 deletions

View File

@ -10,6 +10,7 @@ import (
var (
token = flag.String("token", "", "Service identifier token")
backend = flag.String("backend", "127.0.0.1:9090", "backend TCP/HTTP server")
serverAddr = flag.String("server", "127.0.0.1:9234", "frontend HTTP server")
)
func main() {
@ -18,7 +19,7 @@ func main() {
cfg := &tunnel.ClientConfig{
Identifier: *token,
LocalAddr: *backend,
ServerAddr: "127.0.0.1:9234",
ServerAddr: *serverAddr,
}
client, err := tunnel.NewClient(cfg)