mirror of
https://github.com/byReqz/probehost2.git
synced 2024-11-14 11:23:13 +00:00
remove help placeholder
This commit is contained in:
parent
dcb8ad72e3
commit
0eb1a032dc
7
main.go
7
main.go
@ -14,10 +14,10 @@ import (
|
||||
var logstdout = log.New()
|
||||
var logfile = log.New()
|
||||
|
||||
var logfilepath string
|
||||
var listenport int
|
||||
|
||||
func init() {
|
||||
var logfilepath string
|
||||
flag.StringVar(&logfilepath, "logfilepath", "probehost2.log", "sets the output file for the log")
|
||||
flag.IntVar(&listenport, "port", 8000, "sets the port to listen on")
|
||||
flag.Parse()
|
||||
@ -64,10 +64,6 @@ func runner(remoteip string, command string, args... string) string{
|
||||
return string(cmd)
|
||||
}
|
||||
|
||||
func showhelp(w http.ResponseWriter, req *http.Request) {
|
||||
fmt.Fprintln(w, "placeholder")
|
||||
}
|
||||
|
||||
func validatehosts(hosts []string) []string{
|
||||
var valid []string
|
||||
for _, host := range hosts {
|
||||
@ -113,7 +109,6 @@ func mtr(w http.ResponseWriter, req *http.Request) {
|
||||
func main() {
|
||||
http.HandleFunc("/ping/", ping)
|
||||
http.HandleFunc("/mtr/", mtr)
|
||||
http.HandleFunc("/", showhelp)
|
||||
logstdout.Info("Serving on :", listenport)
|
||||
logfile.Info("Serving on :", listenport)
|
||||
http.ListenAndServe(fmt.Sprint(":", listenport), nil)
|
||||
|
Loading…
Reference in New Issue
Block a user