Back to non https config

This commit is contained in:
Supan Adit Pratama 2021-01-03 21:05:51 +07:00
parent db576e7c1e
commit 4497070e81

View File

@ -7,7 +7,6 @@ import (
"github.com/go-redis/redis" "github.com/go-redis/redis"
"github.com/supanadit/geo-smart-system/system" "github.com/supanadit/geo-smart-system/system"
"log" "log"
"net/http"
) )
func main() { func main() {
@ -21,8 +20,8 @@ func main() {
// Call Router // Call Router
system.Router(r, client) system.Router(r, client)
// Run Server // Run Server
// _ = r.Run(fmt.Sprintf(":%s", system.ServerPort)) _ = r.Run(fmt.Sprintf(":%s", system.ServerPort))
// _ = r.RunTLS(fmt.Sprintf(":%s", system.ServerPort), "./server.crt", "./server.key") // _ = r.RunTLS(fmt.Sprintf(":%s", system.ServerPort), "./server.crt", "./server.key")
err := http.ListenAndServeTLS(fmt.Sprintf(":%s", system.ServerPort), "cert.pem", "key.pem", nil) //err := http.ListenAndServeTLS(fmt.Sprintf(":%s", system.ServerPort), "cert.pem", "key.pem", nil)
log.Fatal(err) log.Fatal(err)
} }