add Docker Compose configuration for Traefik and MySQL, update environment variables
All checks were successful
Build & Publish Docker Image / build-and-push (push) Successful in 44s
All checks were successful
Build & Publish Docker Image / build-and-push (push) Successful in 44s
This commit is contained in:
5
main.go
5
main.go
@@ -4,6 +4,7 @@ import (
|
||||
"fmt"
|
||||
"log"
|
||||
"net/http"
|
||||
"os"
|
||||
"time"
|
||||
|
||||
"github.com/go-chi/chi/v5"
|
||||
@@ -23,6 +24,10 @@ func main() {
|
||||
// Load .env (ignored if not present in production)
|
||||
_ = godotenv.Load()
|
||||
|
||||
if name := os.Getenv("INSTANCE_NAME"); name != "" {
|
||||
log.SetPrefix("[" + name + "] ")
|
||||
}
|
||||
|
||||
cfg := config.Load()
|
||||
|
||||
db, err := database.Connect(cfg)
|
||||
|
||||
Reference in New Issue
Block a user