config

package
v0.0.0-...-6b30812 Latest Latest
Warning

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

Go to latest
Published: Nov 20, 2019 License: BSD-3-Clause Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Config

type Config struct {
	Main       MainConfig
	Mattermost MattermostConfig
	HTTP       HTTPConfig
	Team       map[string]TeamConfig
	Routes     map[string]*RouteConfig
	Modules    map[string][]map[string]interface{}
}

func LoadConfig

func LoadConfig(filename string) (conf *Config, err error)

func (*Config) ModuleDataDir

func (c *Config) ModuleDataDir(name string) string

ModuleDataDir returns the path to a modules data directory.

type HTTPConfig

type HTTPConfig struct {
	Address string
}

type MainConfig

type MainConfig struct {
	Debug      bool
	ExtraDebug bool
	ModulesDir string
	Modules    []string
	DataDir    string
}

type MattermostConfig

type MattermostConfig struct {
	Server       string
	InsecureTLS  bool
	DebugChannel string

	Login struct {
		Username, Password string
	}

	Botid struct {
		Firstname, Lastname, Nickname string
	}
}

type RouteConfig

type RouteConfig struct {
	Enabled         bool
	Channels        []string
	ChannelOverride bool
	Username        string
	Password        string
	Alias           string
	Settings        map[string]interface{}
}

type TeamConfig

type TeamConfig struct {
	Channels []string
}

Jump to

Keyboard shortcuts

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