commands

package
v0.0.0-...-168a2c3 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: May 30, 2019 License: MIT Imports: 19 Imported by: 0

Documentation

Overview

Package commands This version will be built when no tag MULTI is used in go build

Index

Constants

This section is empty.

Variables

View Source
var RootCmd = &cobra.Command{
	Use:              "lachesis",
	Short:            "lachesis consensus",
	TraverseChildren: true,
}

RootCmd is the root command for Lachesis

View Source
var VersionCmd = &cobra.Command{
	Use:   "version",
	Short: "Show version info",
	Run: func(cmd *cobra.Command, args []string) {
		fmt.Println(version.Version)
	},
}

VersionCmd displays the version of lachesis being used

Functions

func AddKeygenFlags

func AddKeygenFlags(cmd *cobra.Command)

AddKeygenFlags adds flags to the keygen command

func AddRunFlags

func AddRunFlags(cmd *cobra.Command)

AddRunFlags adds flags to the Run command

func NewKeygenCmd

func NewKeygenCmd() *cobra.Command

NewKeygenCmd produces a KeygenCmd which creates a key pair

func NewRunCmd

func NewRunCmd() *cobra.Command

NewRunCmd returns the command that starts a Lachesis node

Types

type CLIConfig

type CLIConfig struct {
	Lachesis   lachesis.LachesisConfig `mapstructure:",squash"`
	ProxyAddr  string                  `mapstructure:"proxy-listen"`
	ClientAddr string                  `mapstructure:"client-connect"`
	Standalone bool                    `mapstructure:"standalone"`
	Log2file   bool                    `mapstructure:"log2file"`
	Pidfile    string                  `mapstructure:"pidfile"`
	Syslog     bool                    `mapstructure:"syslog"`
}

CLIConfig contains configuration for the Run command

func NewDefaultCLIConfig

func NewDefaultCLIConfig() *CLIConfig

NewDefaultCLIConfig creates a CLIConfig with default values

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL