pcmt/main.go
leo 9ab2d0ae0b
All checks were successful
continuous-integration/drone Build is passing
continuous-integration/drone/push Build is passing
go: handle host+port combinations,shutdown better
* add log messages telling the user what went wrong if the app fails to
  start
* improve existing log messages
* cleanup: close channels when exiting
* cleanup: stop listening for signals when exiting
2023-05-02 00:04:04 +02:00

17 lines
236 B
Go

package main
import (
"os"
"golang.org/x/exp/slog"
)
func main() {
err := run()
if err != nil {
l := slog.New(slog.NewJSONHandler(os.Stderr))
l.Error("unrecoverable failure, stopping the app", "error", err)
os.Exit(1)
}
}