I think it’s not available right now, but it should be fairly easy to add. All you need to do is add a flag and then set the logger’s level, like this:
func setLogLevel(c *cli.Context) error {
log.SetLevel(log.Level(uint8(c.Int("log-level"))))
return nil
}
...
cli.IntFlag{
Name: "log-level",
Value: 5,
Usage: "debug=5, info=4, warning=3, error=2, fatal=1, panic=0",
EnvVar: "LOG_LEVEL",
},
Finally, add it to tasks:
tasks := []func(*cli.Context) error{
setLogLevel,
setNetID,
setBandConfig,
setDeduplicationDelay,
setGetDownlinkDataDelay,
setCreateGatewayOnStats,
setNodeSessionTTL,
setLogNodeFrames,
setGatewayServerJWTSecret,
setStatsAggregationIntervals,
setTimezone,
printStartMessage,
enableUplinkChannels,
setRedisPool,
setPostgreSQLConnection,
setGatewayBackend,
setApplicationServer,
setNetworkController,
runDatabaseMigrations,
startAPIServer,
startGatewayAPIServer,
startLoRaServer(server),
startStatsServer(gwStats),
}
Unless there’s a reason why this is not implemented, I’ll fork current loraserver and make a PR with this feature.