config

package
v0.3.0 Latest Latest
Warning

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

Go to latest
Published: Mar 7, 2023 License: Apache-2.0 Imports: 9 Imported by: 0

Documentation

Index

Constants

View Source
const PrefixWarrant = "warrant"

Variables

This section is empty.

Functions

This section is empty.

Types

type Config

type Config struct {
	Port            int             `mapstructure:"port"`
	LogLevel        int8            `mapstructure:"logLevel"`
	EnableAccessLog bool            `mapstructure:"enableAccessLog"`
	Datastore       DatastoreConfig `mapstructure:"datastore"`
}

func NewConfig

func NewConfig() Config

type DatastoreConfig

type DatastoreConfig struct {
	MySQL *MySQLConfig `mapstructure:"mysql"`
}

type MySQLConfig

type MySQLConfig struct {
	Username           string `mapstructure:"username"`
	Password           string `mapstructure:"password"`
	Hostname           string `mapstructure:"hostname"`
	Database           string `mapstructure:"database"`
	MaxIdleConnections int    `mapstructure:"maxIdleConnections"`
	MaxOpenConnections int    `mapstructure:"maxOpenConncetions"`
}

Jump to

Keyboard shortcuts

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