Browse Source

cleanup

master
Steve 2 years ago
parent
commit
701dd84163
  1. 1
      go.mod
  2. 2
      main.go

1
go.mod

@ -10,7 +10,6 @@ require (
github.com/spf13/jwalterweatherman v1.1.0 // indirect
github.com/spf13/pflag v1.0.5 // indirect
github.com/spf13/viper v1.6.2
github.com/stryan/go-gopher v0.0.0-20191008152201-adba90945dcb // indirect
golang.org/x/sys v0.0.0-20200212091648-12a6c2dcc1e4 // indirect
golang.org/x/text v0.3.2 // indirect
gopkg.in/ini.v1 v1.52.0 // indirect

2
main.go

@ -54,7 +54,7 @@ func main() {
hole := h.(GopherConfig)
gopher.Handle("/", index(gopher.Dir(hole.RootDir)))
//log.Fatal(gopher.ListenAndServe(hole.Hostname+":"+hole.Port, nil))
server := &gopher.Server{Addr: ":" + hole.Port, Hostname: hole.Hostname, Handler: nil}
server := &gopher.Server{Addr: "0.0.0.0:" + hole.Port, Hostname: hole.Hostname, Handler: nil}
log.Fatal(server.ListenAndServe())
wg.Done()
}(h)

Loading…
Cancel
Save