Documentation ¶
Index ¶
- func IsValidUrl(input string) bool
- type ClientConf
- type InterfaceConfig
- type MqttConfig
- type ServerConf
- type VaultConfig
- func (c *VaultConfig) HasAppRoleLoginInfo() bool
- func (c *VaultConfig) HasTokenInfo() bool
- func (c *VaultConfig) Print()
- func (c *VaultConfig) Verify() error
- func (c *VaultConfig) WithAppRole(appRoleId, appRoleSecret string) *VaultConfig
- func (c *VaultConfig) WithRoleName(roleName string) *VaultConfig
- func (c *VaultConfig) WithVaultToken(vaultToken string) *VaultConfig
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func IsValidUrl ¶
Types ¶
type ClientConf ¶
type ClientConf struct { Host string `json:"host"` KeyPairPath string `json:"keypair_path"` MetricsListener string `json:"metrics_listen",omitempty` Once bool // this is not parsed via json, it's an cli flag MqttConfig *InterfaceConfig }
func ReadClientConfig ¶
func ReadClientConfig(path string) (*ClientConf, error)
func (*ClientConf) Print ¶
func (conf *ClientConf) Print()
func (*ClientConf) Validate ¶
func (conf *ClientConf) Validate() error
type InterfaceConfig ¶
type InterfaceConfig struct {
NetworkInterface string `json:"interface"`
}
func (*InterfaceConfig) Print ¶
func (conf *InterfaceConfig) Print()
func (*InterfaceConfig) Validate ¶
func (conf *InterfaceConfig) Validate() error
type MqttConfig ¶
func (*MqttConfig) Print ¶
func (conf *MqttConfig) Print()
func (*MqttConfig) Validate ¶
func (conf *MqttConfig) Validate() error
type ServerConf ¶
type ServerConf struct { KnownHosts map[string]string `json:"known_hosts"` HostedZoneId string `json:"hosted_zone_id"` MetricsListener string `json:"metrics_listen",omitempty` MqttConfig VaultConfig }
func ReadServerConfig ¶
func ReadServerConfig(path string) (*ServerConf, error)
func (*ServerConf) DecodePublicKeys ¶
func (conf *ServerConf) DecodePublicKeys() map[string]verification.VerificationKey
func (*ServerConf) Print ¶
func (conf *ServerConf) Print()
func (*ServerConf) Validate ¶
func (conf *ServerConf) Validate() error
type VaultConfig ¶
type VaultConfig struct { RoleName string `json:"vault_role_name,omitempty"` VaultAddr string `json:"vault_addr,omitempty"` AppRoleId string `json:"vault_app_role_id,omitempty"` AppRoleSecret string `json:"vault_app_role_secret,omitempty"` VaultToken string `json:"vault_token,omitempty"` }
func GetDefaultVaultConfig ¶
func GetDefaultVaultConfig() VaultConfig
func (*VaultConfig) HasAppRoleLoginInfo ¶
func (c *VaultConfig) HasAppRoleLoginInfo() bool
func (*VaultConfig) HasTokenInfo ¶
func (c *VaultConfig) HasTokenInfo() bool
func (*VaultConfig) Print ¶
func (c *VaultConfig) Print()
func (*VaultConfig) Verify ¶
func (c *VaultConfig) Verify() error
func (*VaultConfig) WithAppRole ¶
func (c *VaultConfig) WithAppRole(appRoleId, appRoleSecret string) *VaultConfig
func (*VaultConfig) WithRoleName ¶
func (c *VaultConfig) WithRoleName(roleName string) *VaultConfig
func (*VaultConfig) WithVaultToken ¶
func (c *VaultConfig) WithVaultToken(vaultToken string) *VaultConfig
Click to show internal directories.
Click to hide internal directories.