Skip to content
This repository has been archived by the owner on Nov 29, 2020. It is now read-only.

Commit

Permalink
web ui address displayed properly in terminal
Browse files Browse the repository at this point in the history
  • Loading branch information
inconshreveable committed Mar 30, 2013
1 parent 305882f commit 0c7bf6a
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 1 deletion.
1 change: 1 addition & 0 deletions src/ngrok/client/state.go
Expand Up @@ -22,6 +22,7 @@ type State struct {
func (s State) GetVersion() string { return "" }
func (s State) GetPublicUrl() string { return s.publicUrl }
func (s State) GetLocalAddr() string { return s.opts.localaddr }
func (s State) GetWebPort() int { return s.opts.webport }
func (s State) GetStatus() string { return s.status }
func (s State) GetProtocol() proto.Protocol { return s.protocol }
func (s State) IsStopping() bool { return s.stopping }
Expand Down
1 change: 1 addition & 0 deletions src/ngrok/client/ui/interface.go
Expand Up @@ -11,6 +11,7 @@ type State interface {
GetLocalAddr() string
GetStatus() string
GetProtocol() proto.Protocol
GetWebPort() int
IsStopping() bool
GetConnectionMetrics() (metrics.Meter, metrics.Timer)
GetBytesInMetrics() (metrics.Counter, metrics.Histogram)
Expand Down
2 changes: 1 addition & 1 deletion src/ngrok/client/ui/terminal.go
Expand Up @@ -106,7 +106,7 @@ func (t *TermView) draw() {
printf(0, 3, "%-30s%s", "Version", state.GetVersion())
printf(0, 4, "%-30s%s", "Protocol", state.GetProtocol().GetName())
printf(0, 5, "%-30s%s -> %s", "Forwarding", state.GetPublicUrl(), state.GetLocalAddr())
printf(0, 6, "%-30s%s", "HTTP Dashboard", "http://127.0.0.1:9999")
printf(0, 6, "%-30s%s", "Web Interface", "http://127.0.0.1:%d", state.GetWebPort())

connMeter, connTimer := state.GetConnectionMetrics()
printf(0, 7, "%-30s%d", "# Conn", connMeter.Count())
Expand Down

0 comments on commit 0c7bf6a

Please sign in to comment.