mirror of
https://github.com/safing/portmaster
synced 2025-09-02 10:39:22 +00:00
Merge pull request #17 from safing/fix/data-root-init
Fix setting data root in startup procedure
This commit is contained in:
commit
a2a52eb7cd
2 changed files with 5 additions and 2 deletions
|
@ -4,6 +4,8 @@ import (
|
||||||
"errors"
|
"errors"
|
||||||
"flag"
|
"flag"
|
||||||
|
|
||||||
|
"github.com/safing/portbase/config"
|
||||||
|
|
||||||
"github.com/safing/portbase/api"
|
"github.com/safing/portbase/api"
|
||||||
"github.com/safing/portbase/database/dbmodule"
|
"github.com/safing/portbase/database/dbmodule"
|
||||||
"github.com/safing/portbase/modules"
|
"github.com/safing/portbase/modules"
|
||||||
|
@ -43,8 +45,9 @@ func prepBase() error {
|
||||||
return err
|
return err
|
||||||
}
|
}
|
||||||
|
|
||||||
// set database location
|
// set data location
|
||||||
dbmodule.SetDatabaseLocation("", structure.Root())
|
dbmodule.SetDatabaseLocation("", structure.Root())
|
||||||
|
config.SetDataRoot(structure.Root())
|
||||||
|
|
||||||
// init config
|
// init config
|
||||||
logFlagOverrides()
|
logFlagOverrides()
|
||||||
|
|
2
main.go
2
main.go
|
@ -33,7 +33,7 @@ func init() {
|
||||||
|
|
||||||
func main() {
|
func main() {
|
||||||
// Set Info
|
// Set Info
|
||||||
info.Set("Portmaster", "0.3.8", "AGPLv3", true)
|
info.Set("Portmaster", "0.3.9", "AGPLv3", true)
|
||||||
|
|
||||||
// Start
|
// Start
|
||||||
err := modules.Start()
|
err := modules.Start()
|
||||||
|
|
Loading…
Add table
Reference in a new issue