mirror of
https://gitlab.com/pulsechaincom/erigon-pulse.git
synced 2024-12-24 20:47:16 +00:00
b405dfdff7
Added separate logging to devnet nodes - Created two log files for the mining and non-mining nodes - Piped log outputs to the two separate log files
25 lines
509 B
Go
25 lines
509 B
Go
package main
|
|
|
|
import (
|
|
"sync"
|
|
|
|
"github.com/ledgerwatch/erigon/cmd/devnet/devnetutils"
|
|
"github.com/ledgerwatch/erigon/cmd/devnet/node"
|
|
)
|
|
|
|
func main() {
|
|
// wait group variable to prevent main function from terminating until routines are finished
|
|
var wg sync.WaitGroup
|
|
|
|
// remove the old logs from previous runs
|
|
devnetutils.DeleteLogs()
|
|
|
|
defer devnetutils.ClearDevDB()
|
|
|
|
// start the first erigon node in a go routine
|
|
node.Start(&wg)
|
|
|
|
// wait for all goroutines to complete before exiting
|
|
wg.Wait()
|
|
}
|