You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: cmd/db-manager/v1beta1/main.go
+5-3
Original file line number
Diff line number
Diff line change
@@ -35,7 +35,7 @@ import (
35
35
)
36
36
37
37
const (
38
-
port="0.0.0.0:6789"
38
+
defaultListenAddress="0.0.0.0:6789"
39
39
defaultConnectTimeout=time.Second*60
40
40
)
41
41
@@ -90,7 +90,9 @@ func (s *server) Check(ctx context.Context, in *health_pb.HealthCheckRequest) (*
90
90
91
91
funcmain() {
92
92
varconnectTimeout time.Duration
93
+
varlistenAddressstring
93
94
flag.DurationVar(&connectTimeout, "connect-timeout", defaultConnectTimeout, "Timeout before calling error during database connection. (e.g. 120s)")
95
+
flag.StringVar(&listenAddress, "listen-address", defaultListenAddress, "The network interface or IP address to receive incoming connections. (e.g. 0.0.0.0:6789)")
94
96
flag.Parse()
95
97
96
98
varerrerror
@@ -104,13 +106,13 @@ func main() {
104
106
klog.Fatalf("Failed to open db connection: %v", err)
0 commit comments