You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

19 lines
284B

  1. package http
  2. import (
  3. "github.com/gorilla/mux"
  4. "log"
  5. "net/http"
  6. )
  7. func Start(listen string) error {
  8. router := mux.NewRouter()
  9. // TODO add handlers
  10. err := http.ListenAndServe(listen, router)
  11. if err != nil {
  12. log.Println("HTTP server listening on ", listen)
  13. }
  14. return err
  15. }