config

package
v0.0.0-...-9048091 Latest Latest
Warning

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

Go to latest
Published: May 8, 2017 License: Apache-2.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	Help    bool
	Verbose bool

	Role string

	ConfigFile string
)
View Source
var GlobalConfig = &Config{}

Functions

func Init

func Init()

func ShowHelp

func ShowHelp(ret int)
func ShowLogo() string

Types

type Config

type Config struct {
	LogConfig    LogConfig    `yaml:"log"`
	RouterConfig RouterConfig `yaml:"router"`
}

type LogConfig

type LogConfig struct {
	AccessLogPath  string `yaml:"access_log_path"`
	AccessLogLevel string `yaml:"access_log_level"`
	AppLogPath     string `yaml:"app_log_path"`
	AppLogLevel    string `yaml:"app_log_level"`
	StatLogPath    string `yaml:"stat_log_path"`
	StatLogLevel   string `yaml:"stat_log_level"`
}

type RouterConfig

type RouterConfig struct {
	Host       string `yaml:"host"`
	Port       int    `yaml:"port"`
	ReplicaNum int    `yaml:"replica_num"`
}

Jump to

Keyboard shortcuts

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