mirror of https://github.com/poanetwork/quorum.git
main loop uses new flags and common methods in util: db, keymanager set up; passes KeyRing/Session string to gui
This commit is contained in:
parent
12fbb7ae5c
commit
e43e4ff2c1
|
@ -30,10 +30,14 @@ func main() {
|
|||
|
||||
utils.InitLogging(Datadir, LogFile, LogLevel, DebugFile)
|
||||
|
||||
ethereum := utils.NewEthereum(UseUPnP, OutboundPort, MaxPeer)
|
||||
db := utils.NewDatabase()
|
||||
|
||||
keyManager := utils.NewKeyManager(KeyStore, Datadir, db)
|
||||
|
||||
// create, import, export keys
|
||||
utils.KeyTasks(GenAddr, ImportKey, ExportKey, NonInteractive)
|
||||
utils.KeyTasks(keyManager, KeyRing, GenAddr, SecretFile, ExportDir, NonInteractive)
|
||||
|
||||
ethereum := utils.NewEthereum(db, keyManager, UseUPnP, OutboundPort, MaxPeer)
|
||||
|
||||
if ShowGenesis {
|
||||
utils.ShowGenesis(ethereum)
|
||||
|
@ -43,7 +47,7 @@ func main() {
|
|||
utils.StartRpc(ethereum, RpcPort)
|
||||
}
|
||||
|
||||
gui := ethui.New(ethereum, LogLevel)
|
||||
gui := ethui.New(ethereum, KeyRing, LogLevel)
|
||||
|
||||
utils.RegisterInterrupt(func(os.Signal) {
|
||||
gui.Stop()
|
||||
|
|
Loading…
Reference in New Issue