Set outer ports in .env

This commit is contained in:
cdricms
2025-01-14 14:10:40 +01:00
parent fd834ea84a
commit 8aadc810d1
5 changed files with 26 additions and 17 deletions

View File

@@ -18,7 +18,7 @@ func main() {
if err != nil {
log.Fatalf("Error loading .env file: %v", err)
}
port := os.Getenv("BACKEND_PORT")
port := os.Getenv("BACKEND_DOCKER_PORT")
http.HandleFunc("/", handler)
fmt.Printf("Serving on port %s\n", port)
err = http.ListenAndServe(fmt.Sprintf(":%s", port), nil)