aboutsummaryrefslogtreecommitdiffstats
path: root/dex
diff options
context:
space:
mode:
authorWei-Ning Huang <w@cobinhood.com>2018-10-15 12:16:18 +0800
committerWei-Ning Huang <w@byzantine-lab.io>2019-06-12 17:23:39 +0800
commit2e1556d551420e5f52d6e4e157b46963277eaccd (patch)
tree03875aaa88fb06ac64738c0c4d38b9a703a0ca90 /dex
parent09496d7fa81e7ab90131a648da0a870b7e0ac7bf (diff)
downloadgo-tangerine-2e1556d551420e5f52d6e4e157b46963277eaccd.tar.gz
go-tangerine-2e1556d551420e5f52d6e4e157b46963277eaccd.tar.zst
go-tangerine-2e1556d551420e5f52d6e4e157b46963277eaccd.zip
dex: move dexcon blockdb into datadir
Diffstat (limited to 'dex')
-rw-r--r--dex/backend.go4
1 files changed, 3 insertions, 1 deletions
diff --git a/dex/backend.go b/dex/backend.go
index 3d59d9f2c..0e475dec0 100644
--- a/dex/backend.go
+++ b/dex/backend.go
@@ -19,6 +19,7 @@ package dex
import (
"fmt"
+ "path/filepath"
"time"
dexCore "github.com/dexon-foundation/dexon-consensus-core/core"
@@ -82,7 +83,8 @@ type Dexon struct {
func New(ctx *node.ServiceContext, config *Config) (*Dexon, error) {
// Consensus.
- db, err := blockdb.NewLevelDBBackedBlockDB("main.blockdb")
+ blockDBPath := filepath.Join(ctx.Config.DataDir, "dexcon", "blockdb")
+ db, err := blockdb.NewLevelDBBackedBlockDB(blockDBPath)
if err != nil {
panic(err)
}