Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Config ¶
type Config struct { WingCommander WingCommanderParameters `mapstructure:"wingcommander"` AppAnalytics WingCommanderAnalytics `mapstructure:"appanalytics"` Telegram TelegramParameters `mapstructure:"telegram"` Monitor MonitorParameters `mapstructure:"monitor"` SkyManager SkyManagerParameters `mapstructure:"skymanager"` }
Config structure models the applications configuration structure
func LoadConfigParameters ¶
func LoadConfigParameters(filename, pathname string, defaults map[string]interface{}) (config Config, err error)
LoadConfigParameters will load the applications configuration from the specified configuration file `filename` (note file extension must not be provided) in the specified path `pathname`. The function also provides the ability to specify configuration defaults. An `error` will be returned if any errors occur. A valid `Config` struct will be returned on success.
func (*Config) PrintConfig ¶
func (c *Config) PrintConfig()
PrintConfig will log debug information for the passed Config structure
type MonitorParameters ¶
type MonitorParameters struct { IntervalSec time.Duration `mapstructure:"intervalsec"` HeartbeatIntMin time.Duration `mapstructure:"heartbeatintmin"` DiscoveryMonitorIntMin time.Duration `mapstructure:"discoverymonitorintmin"` }
MonitorParameters struct defines the configuration parameters that are used by the Monitor which polls the SkyManager
type SkyManagerParameters ¶
type SkyManagerParameters struct { Address string `mapstructure:"address"` DiscoveryAddress string `mapstructure:"discoveryaddress"` }
SkyManagerParameters struct defines the configuration parameters that are used to manage connectivity with the Skywire Manager
type TelegramParameters ¶
type TelegramParameters struct { APIKey string `mapstructure:"apikey"` ChatID int64 `mapstructure:"chatid"` Admin string `mapstructure:"admin"` Debug bool `mapstructure:"debug"` }
TelegramParameters struct defines the configuration parameters that are used to manage Wing Commander application integrationw it Telegram
type WingCommanderAnalytics ¶
type WingCommanderAnalytics struct { ClientUUID string `mapstructure:"clientuuid"` UserID string `mapstructure:"userid"` }
WingCommanderAnalytics struct defines the parameters that are used if Analytics is enabled
type WingCommanderParameters ¶
type WingCommanderParameters struct { TwoFactorEnabled bool `mapstructure:"twofactorenabled"` AnalyticsEnabled bool `mapstructure:"analyticsenabled"` }
WingCommanderParameters struct defines the configuration parameters that are used to manage runtime config for the Wing Commander application