jokes-bapak2/api/main.go

19 lines
304 B
Go
Raw Normal View History

2021-05-02 07:49:13 +00:00
package main
import (
2021-05-02 07:58:37 +00:00
"log"
2021-05-02 07:49:13 +00:00
"net/http"
"github.com/aldy505/jokes-bapak2-api/api/routes"
)
func main() {
routes := routes.Setup()
server := &http.Server{
Addr: "localhost:3000",
Handler: routes,
}
2021-05-02 07:58:37 +00:00
log.Printf("[info] Server is running on http://localhost:3000")
2021-05-02 07:49:13 +00:00
server.ListenAndServe()
}