Added port configuration

This commit is contained in:
Eduard Urbach 2024-04-04 12:13:23 +02:00
parent b185fe013d
commit 584c1df91a
Signed by: akyoto
GPG Key ID: C874F672B1AF20C0

8
App.go
View File

@ -107,7 +107,13 @@ func (app *App) Run() {
return render(ctx, head, content)
})
s.Run(":8080")
address := os.Getenv("LISTEN")
if address == "" {
address = ":8080"
}
s.Run(address)
}
func load(path string) string {