cliconfig

package
v0.4.33 Latest Latest
Warning

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

Go to latest
Published: Aug 23, 2021 License: Apache-2.0 Imports: 15 Imported by: 0

Documentation

Index

Constants

View Source
const (
	// ConfigSnapID is the name/ID of the configuration snap
	ConfigSnapID = "configurationsnap"
)

Variables

This section is empty.

Functions

func InitAppName

func InitAppName(flags *pflag.FlagSet)

InitAppName initializes the application name from the provided arguments

func InitAppVer added in v0.2.0

func InitAppVer(flags *pflag.FlagSet)

InitAppVer initializes the app ver from the provided arguments

func InitCSRCommonName added in v0.1.9

func InitCSRCommonName(flags *pflag.FlagSet)

InitCSRCommonName initializes the CSR common name field

func InitChannelID

func InitChannelID(flags *pflag.FlagSet)

InitChannelID initializes the channel ID from the provided arguments

func InitClientConfigFile

func InitClientConfigFile(flags *pflag.FlagSet)

InitClientConfigFile initializes the config file path from the provided arguments

func InitComponentName added in v0.2.0

func InitComponentName(flags *pflag.FlagSet)

InitComponentName initializes the component name from the provided arguments

func InitComponentVer added in v0.2.0

func InitComponentVer(flags *pflag.FlagSet)

InitComponentVer initializes the component ver from the provided arguments

func InitConfig

func InitConfig() error

InitConfig initializes the configuration

func InitConfigFile

func InitConfigFile(flags *pflag.FlagSet)

InitConfigFile initializes the org configuration file from the provided arguments

func InitConfigKey

func InitConfigKey(flags *pflag.FlagSet)

InitConfigKey initializes the config key from the provided arguments

func InitConfigString

func InitConfigString(flags *pflag.FlagSet)

InitConfigString initializes the config string from the provided arguments

func InitEphemeralFlag added in v0.1.6

func InitEphemeralFlag(flags *pflag.FlagSet)

InitEphemeralFlag initializes the ephemeral flag from the provided arguments

func InitKeyType added in v0.1.6

func InitKeyType(flags *pflag.FlagSet)

InitKeyType initializes the KeyType from the provided arguments

func InitLoggingLevel

func InitLoggingLevel(flags *pflag.FlagSet)

InitLoggingLevel initializes the logging level from the provided arguments

func InitMspID

func InitMspID(flags *pflag.FlagSet)

InitMspID initializes the MSP ID from the provided arguments

func InitNoPrompt

func InitNoPrompt(flags *pflag.FlagSet)

InitNoPrompt initializes the "no-prompt" flag from the provided arguments

func InitOrgID

func InitOrgID(flags *pflag.FlagSet)

InitOrgID initializes the org ID from the provided arguments

func InitOutputFormat

func InitOutputFormat(flags *pflag.FlagSet)

InitOutputFormat initializes the print format from the provided arguments

func InitPeerID

func InitPeerID(flags *pflag.FlagSet)

InitPeerID initializes the peer ID from the provided arguments

func InitPeerURL

func InitPeerURL(flags *pflag.FlagSet)

InitPeerURL initializes the peer URL from the provided arguments

func InitSigAlg added in v0.1.6

func InitSigAlg(flags *pflag.FlagSet)

InitSigAlg initializes the signature algorithm from the provided arguments

func InitTimeout

func InitTimeout(flags *pflag.FlagSet)

InitTimeout initializes the timeout from the provided arguments

func InitUserName

func InitUserName(flags *pflag.FlagSet)

InitUserName initializes the user name from the provided arguments

func InitUserPassword

func InitUserPassword(flags *pflag.FlagSet)

InitUserPassword initializes the user password from the provided arguments

Types

type CLIConfig

type CLIConfig struct {
	fabApi.EndpointConfig
	mspApi.IdentityConfig
	core.CryptoSuiteConfig
	// contains filtered or unexported fields
}

CLIConfig overrides certain configuration values with those supplied on the command-line

func Config

func Config() *CLIConfig

Config returns the CLI configuration

func (*CLIConfig) AppName

func (c *CLIConfig) AppName() string

AppName returns an application name (used in the config query command)

func (*CLIConfig) AppVer added in v0.2.0

func (c *CLIConfig) AppVer() string

AppVer returns an app ver (used in the config query command)

func (*CLIConfig) CSRCommonName added in v0.1.9

func (c *CLIConfig) CSRCommonName() string

CSRCommonName returns CSR common name (used in the config generteCSR command)

func (*CLIConfig) ChannelID

func (c *CLIConfig) ChannelID() string

ChannelID returns the channel ID

func (*CLIConfig) ClientConfigFile added in v0.2.0

func (c *CLIConfig) ClientConfigFile() string

ClientConfigFile returns the org config file

func (*CLIConfig) ComponentName added in v0.2.0

func (c *CLIConfig) ComponentName() string

ComponentName returns an component name (used in the config query command)

func (*CLIConfig) ComponentVer added in v0.2.0

func (c *CLIConfig) ComponentVer() string

ComponentVer returns an component ver (used in the config query command)

func (*CLIConfig) ConfigFile

func (c *CLIConfig) ConfigFile() string

ConfigFile returns the org config file

func (*CLIConfig) ConfigKey

func (c *CLIConfig) ConfigKey() string

ConfigKey returns the config key in JSON format

func (*CLIConfig) ConfigString

func (c *CLIConfig) ConfigString() string

ConfigString returns the config string in JSON format

func (*CLIConfig) EphemeralFlag added in v0.1.6

func (c *CLIConfig) EphemeralFlag() string

EphemeralFlag returns an ephemeral flag (used in the config generteCSR command)

func (*CLIConfig) GetMspID

func (c *CLIConfig) GetMspID() string

GetMspID returns the MSP ID

func (*CLIConfig) IsLoggingEnabledFor

func (c *CLIConfig) IsLoggingEnabledFor(level logging.Level) bool

IsLoggingEnabledFor indicates whether the logger is enabled for the given logging level

func (*CLIConfig) KeyType added in v0.1.6

func (c *CLIConfig) KeyType() string

KeyType returns an KeyType name (used in the config generteCSR command)

func (*CLIConfig) Logger

func (c *CLIConfig) Logger() *logging.Logger

Logger returns the Logger for the CLI tool

func (*CLIConfig) LoggingLevel

func (c *CLIConfig) LoggingLevel() string

LoggingLevel specifies the logging level (DEBUG, INFO, WARNING, ERROR, or CRITICAL)

func (*CLIConfig) NoPrompt

func (c *CLIConfig) NoPrompt() bool

NoPrompt is true if the user does not want top be prompted to confirm an update or delete

func (*CLIConfig) OrgID

func (c *CLIConfig) OrgID() string

OrgID specifies the ID of the current organization. If multiple org IDs are specified then the first one is returned.

func (*CLIConfig) OutputFormat

func (c *CLIConfig) OutputFormat() string

OutputFormat returns the print (output) format for a block

func (*CLIConfig) PeerID

func (c *CLIConfig) PeerID() string

PeerID returns the ID of the peer (used in the config query command)

func (*CLIConfig) Peers added in v0.4.3

func (c *CLIConfig) Peers() []string

Peers returns a list of peer URLs

func (*CLIConfig) SigAlg added in v0.1.6

func (c *CLIConfig) SigAlg() string

SigAlg returns an signature algorithm (used in the config generteCSR command)

func (*CLIConfig) Timeout

func (c *CLIConfig) Timeout(conn fabApi.TimeoutType) time.Duration

Timeout returns the timeout (in milliseconds) for various operations

func (*CLIConfig) UserName

func (c *CLIConfig) UserName() string

UserName returns the name of the enrolled user

func (*CLIConfig) UserPassword

func (c *CLIConfig) UserPassword() string

UserPassword is the password to use when enrolling a user

Jump to

Keyboard shortcuts

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