Documentation ¶
Overview ¶
Package config handles configuration of the bot and is also a store for global variables such as version, etc which are set on building via the Makefile.
Index ¶
Constants ¶
This section is empty.
Variables ¶
var BuildHash = unset
BuildHash is set by the Makefile and is the current git hash when the binary was built. Note if there are uncommitted changes in repository then the hash may not be accurate.
var BuildTimestamp = unset
BuildTimestamp is set by the Makefile and is the time the binary was built.
var BuildVersion = unset
BuildVersion is set by the Makefile and is taken from the git branch, or git tag.
Functions ¶
Types ¶
type AWS ¶ added in v0.1.13
AWS options.
func (*AWS) Configure ¶ added in v0.1.13
func (a *AWS) Configure(opts *goconfigure.Options)
Configure the AWS options.
type Discord ¶ added in v0.1.13
Discord options.
func (*Discord) Configure ¶ added in v0.1.13
func (d *Discord) Configure(opts *goconfigure.Options)
Configure the Discord options.
type Limiter ¶ added in v0.1.5
type Limiter struct { // Depth of the limiter (i.e. number of distinct items to hold) Depth int // Limit at which the limiter will trip (i.e. the number of time something // needs to be seen before the limiter trips) Limit int // TTL for the items in the limiter TTL time.Duration }
Limiter configuration.
type Limiters ¶ added in v0.1.5
type Limiters struct { // Source limiter rate limits connections from the same source. Source Limiter // User limiter rate limits connections from the same user. User Limiter }
Limiters in use by the system.
func (*Limiters) Configure ¶ added in v0.1.5
func (l *Limiters) Configure(opts *goconfigure.Options)
Configure the limiter.
type Security ¶ added in v0.1.5
type Security struct { // Secret used to encode the JWT tokens Secret string // SessionTTL is the length of time a session will be valid for before // it requires re-authentication. SessionTTL time.Duration // Timebox is the minimum time it will take for a login attempt to // return. Timebox time.Duration Limiters }
Security options.
func (*Security) Configure ¶ added in v0.1.5
func (s *Security) Configure(opts *goconfigure.Options)
Configure the security options.
type Server ¶ added in v0.1.13
Server options.
func (*Server) Configure ¶ added in v0.1.13
func (s *Server) Configure(opts *goconfigure.Options)
Configure the Server options.