File tree Expand file tree Collapse file tree 3 files changed +4
-2
lines changed
Expand file tree Collapse file tree 3 files changed +4
-2
lines changed Original file line number Diff line number Diff line change 11FROM golang:latest
22
3- ENV PORT
43
54ENV GO111MODULE=on
65
Original file line number Diff line number Diff line change @@ -3,14 +3,15 @@ package apihandler
33import (
44 "encoding/json"
55 "fmt"
6+ "log"
67 "net/http"
78
89 "github.com/gorilla/mux"
910 db "primitivo.fr/applinh/GoFire/db"
1011)
1112
1213func HomeHandler (w http.ResponseWriter , r * http.Request ) {
13- fmt .Println ("ok " )
14+ log .Println ("Your request has been correctly received on GET / " )
1415}
1516
1617func GET_ResHandler (w http.ResponseWriter , r * http.Request ) {
Original file line number Diff line number Diff line change @@ -33,6 +33,8 @@ func main() {
3333 r .HandleFunc ("/{res}" , api .POST_ResHandler ).Methods ("POST" )
3434 r .HandleFunc ("/{res}/{id}" , api .PATCH_ResHandler ).Methods ("PATCH" )
3535
36+ log .Println ("Starting FireGo on port " + port )
37+
3638 log .Fatal (http .ListenAndServe ("0.0.0.0:" + port , r ))
3739
3840}
You can’t perform that action at this time.
0 commit comments