1
0
mirror of https://github.com/imgproxy/imgproxy.git synced 2024-11-24 08:12:38 +02:00
imgproxy/main.go

22 lines
398 B
Go
Raw Normal View History

2017-06-20 15:58:55 +02:00
package main
import (
"log"
"net/http"
"time"
)
func main() {
s := &http.Server{
Addr: conf.Bind,
2017-07-04 16:05:53 +02:00
Handler: newHttpHandler(),
2017-06-20 15:58:55 +02:00
ReadTimeout: time.Duration(conf.ReadTimeout) * time.Second,
WriteTimeout: time.Duration(conf.WriteTimeout) * time.Second,
MaxHeaderBytes: 1 << 20,
}
log.Printf("Starting server at %s\n", conf.Bind)
log.Fatal(s.ListenAndServe())
}