server.go 299 B

123456789101112
  1. package main
  2. import (
  3. "log"
  4. "net/http"
  5. )
  6. func main() {
  7. fs := http.FileServer(http.Dir("/static"))
  8. http.Handle("/", fs)
  9. log.Panic(http.ListenAndServe(":80", nil)) // #nosec G114 -- Ignoring for test-code: G114: Use of net/http serve function that has no support for setting timeouts (gosec)
  10. }