move http server into a sep goroutine