Add flag to disable startup banner
This commit is contained in:
@@ -27,6 +27,7 @@ type sonic struct {
|
|||||||
LogLevel string `default:"info"`
|
LogLevel string `default:"info"`
|
||||||
DevDisableAuthentication bool `default:"false"`
|
DevDisableAuthentication bool `default:"false"`
|
||||||
DevDisableFileCheck bool `default:"false"`
|
DevDisableFileCheck bool `default:"false"`
|
||||||
|
DevDisableBanner bool `default:"false"`
|
||||||
}
|
}
|
||||||
|
|
||||||
var Sonic *sonic
|
var Sonic *sonic
|
||||||
|
|||||||
@@ -24,7 +24,9 @@ type Server struct {
|
|||||||
|
|
||||||
func New(importer *scanner_legacy.Importer) *Server {
|
func New(importer *scanner_legacy.Importer) *Server {
|
||||||
a := &Server{Importer: importer}
|
a := &Server{Importer: importer}
|
||||||
|
if !conf.Sonic.DevDisableBanner {
|
||||||
showBanner(Version)
|
showBanner(Version)
|
||||||
|
}
|
||||||
initMimeTypes()
|
initMimeTypes()
|
||||||
a.initRoutes()
|
a.initRoutes()
|
||||||
a.initImporter()
|
a.initImporter()
|
||||||
|
|||||||
Reference in New Issue
Block a user