Documentation ¶
Index ¶
- Constants
- func GetBMCCFGFile() string
- func GetBMCHomeDir() string
- func IsInitialized() bool
- type BMCConfig
- func (bc *BMCConfig) GetKeyPath() string
- func (bc *BMCConfig) GetPrivKey() (priv *rsa.PrivateKey)
- func (bc *BMCConfig) GetPubKey() (pub *rsa.PublicKey)
- func (bc *BMCConfig) InitCfg() *BMCConfig
- func (bc *BMCConfig) Load() *BMCConfig
- func (bc *BMCConfig) Save()
- func (bc *BMCConfig) SetPrivKey(priv *rsa.PrivateKey)
- func (bc *BMCConfig) SetPubKey(pub *rsa.PublicKey)
Constants ¶
View Source
const ( BMC_HomeDir = ".bmc" BMC_CFG_FileName = "bmc.json" )
Variables ¶
This section is empty.
Functions ¶
func GetBMCCFGFile ¶
func GetBMCCFGFile() string
func GetBMCHomeDir ¶
func GetBMCHomeDir() string
func IsInitialized ¶
func IsInitialized() bool
Types ¶
type BMCConfig ¶
type BMCConfig struct { MgtHttpPort int `json:"mgthttpport"` KeyPath string `json:"keypath"` CmdListenPort string `json:"cmdlistenport"` PrivKey *rsa.PrivateKey `json:"-"` PubKey *rsa.PublicKey `json:"-"` PKAddr string `json:"-"` RemoteServer string `json:"remoteserver"` }
func LoadFromCfgFile ¶
func LoadFromCmd ¶
func (*BMCConfig) GetKeyPath ¶
func (*BMCConfig) GetPrivKey ¶
func (bc *BMCConfig) GetPrivKey() (priv *rsa.PrivateKey)
func (*BMCConfig) SetPrivKey ¶
func (bc *BMCConfig) SetPrivKey(priv *rsa.PrivateKey)
Click to show internal directories.
Click to hide internal directories.