0.2.55 - Remote config/Request fixes
This commit is contained in:
@@ -49,7 +49,18 @@ func main() {
|
||||
logLevel := logging.ParseLevel(os.Getenv("MEMBY_LOG_LEVEL"))
|
||||
logCapacity := logging.ParseCapacity(os.Getenv("MEMBY_LOG_BUFFER_CAPACITY"), 5_000)
|
||||
logFormat := logging.ParseFormat(os.Getenv("MEMBY_LOG_FORMAT"))
|
||||
log, events := logging.NewBuffered(os.Stdout, logLevel, logCapacity, logFormat)
|
||||
logHistoryPath := strings.TrimSpace(os.Getenv("MEMBY_LOG_HISTORY_PATH"))
|
||||
if logHistoryPath == "" {
|
||||
logHistoryPath = "/data/logs/events.jsonl"
|
||||
}
|
||||
log, events, err := logging.NewPersistentBuffered(
|
||||
os.Stdout, logLevel, logCapacity, logFormat, logHistoryPath,
|
||||
)
|
||||
if err != nil {
|
||||
os.Stderr.WriteString("open persistent log history: " + err.Error() + "\n")
|
||||
os.Exit(1)
|
||||
}
|
||||
defer events.Close()
|
||||
// Every line names the build that wrote it. A gateway is deployed from a working
|
||||
// tree, often while a television is running an older app, so "which server said
|
||||
// this" is a real question that a reader should never have to scroll for.
|
||||
|
||||
Reference in New Issue
Block a user