feat: implement legacy operation logging
This commit is contained in:
@@ -11,6 +11,7 @@ import (
|
||||
"chfs-ng/internal/api"
|
||||
"chfs-ng/internal/auth"
|
||||
"chfs-ng/internal/config"
|
||||
"chfs-ng/internal/opslog"
|
||||
"chfs-ng/internal/storage"
|
||||
)
|
||||
|
||||
@@ -67,7 +68,7 @@ func main() {
|
||||
if len(cfg.Path) == 1 {
|
||||
store = storage.Local{Root: root}
|
||||
}
|
||||
srv := &api.Server{Store: store, Auth: mgr, Sessions: map[string]*auth.Account{}, WebDAVRoot: root, Allow: cfg.Allow, MultiRoot: len(cfg.Path) > 1, RemoveMode: cfg.FileRemove}
|
||||
srv := &api.Server{Store: store, Auth: mgr, Sessions: map[string]*auth.Account{}, WebDAVRoot: root, Allow: cfg.Allow, MultiRoot: len(cfg.Path) > 1, RemoveMode: cfg.FileRemove, Log: opslog.New(cfg.Log)}
|
||||
addr := ":" + itoa(cfg.Port)
|
||||
log.Printf("chfs-ng listening on %s root=%s removeMode=%d", addr, filepath.Clean(root), cfg.FileRemove)
|
||||
if cfg.SSLCert != "" && cfg.SSLKey != "" {
|
||||
|
||||
Reference in New Issue
Block a user