conf

package
v1.10.0 Latest Latest
Warning

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

Go to latest
Published: Jan 28, 2023 License: Apache-2.0 Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func IsValidUrl

func IsValidUrl(input string) bool

Types

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

type MqttConfig struct {
	Brokers        []string `json:"brokers" env:"DYNDNS_BROKERS" envSeparator:";"`
	ClientId       string   `json:"client_id" env:"DYNDNS_CLIENT_ID"`
	CaCertFile     string   `json:"tls_ca_cert" env:"DYNDNS_TLS_CA"`
	ClientCertFile string   `json:"tls_client_cert" env:"DYNDNS_TLS_CERT"`
	ClientKeyFile  string   `json:"tls_client_key" env:"DYNDNS_TLS_KEY"`
	TlsInsecure    bool     `json:"tls_insecure" env:"DYNDNS_TLS_INSECURE"`
}

func (*MqttConfig) Print

func (conf *MqttConfig) Print()

func (*MqttConfig) TlsConfig added in v1.6.0

func (conf *MqttConfig) TlsConfig() *tls.Config

func (*MqttConfig) Validate

func (conf *MqttConfig) 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

Jump to

Keyboard shortcuts

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