working commit

This commit is contained in:
2026-02-21 20:07:37 +02:00
parent c6ce50308d
commit 685880c8a8
45 changed files with 255 additions and 453 deletions
+5 -6
View File
@@ -78,6 +78,10 @@ func (srv *Server) SetPort(port int64) {
srv.conf.Service.Port = port
}
func (srv *Server) SetAsDaemon(asDaemon bool) {
srv.conf.AsDaemon = asDaemon
}
func (srv *Server) Configure() error {
var err error
srv.logg.Infof("Configuration server")
@@ -94,11 +98,6 @@ func (srv *Server) Configure() error {
if err != nil {
return err
}
err = srv.conf.ReadOptions()
if err != nil {
return err
}
return err
}
@@ -159,7 +158,7 @@ func (srv *Server) Build() error {
// Creating datadir
datadir := srv.conf.Datadir
if !auxtool.DirExists(datadir) {
if !auxtool.DirExists(datadir) { // TODO: check access to dir
srv.logg.Infof("Creating data directory %s ", datadir)
err = os.MkdirAll(datadir, 0750)
if err != nil {