(ctx *cli.Context)
| 110 | } |
| 111 | |
| 112 | func run(ctx *cli.Context) error { |
| 113 | isRunningChain = true |
| 114 | err := times.InvalidSystemClock() |
| 115 | if err != nil { |
| 116 | log.Warn(InvalidSystemClockWarn) |
| 117 | log.Fatalf("system clock need to be synchronized.there is more than %v seconds gap between ntp and this server", times.MaxGapDuration) |
| 118 | } |
| 119 | |
| 120 | if ctx.IsSet(flags.MineFlagName) && ctx.IsSet(flags.ValidatorFlagName) { |
| 121 | log.Fatalf("A node cannot be both miner and validator.") |
| 122 | } |
| 123 | |
| 124 | n := createNode(ctx) |
| 125 | bootstrap(ctx, n) |
| 126 | n.Wait() |
| 127 | return nil |
| 128 | } |
| 129 | |
| 130 | // Register chain services for a *full* node. |
| 131 | func registerChainService(cfg *cpc.Config, n *node.Node, cliCtx *cli.Context) { |
nothing calls this directly
no test coverage detected