config

package
v0.3.0 Latest Latest
Warning

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

Go to latest
Published: Sep 10, 2020 License: MPL-2.0 Imports: 9 Imported by: 0

Documentation

Index

Constants

View Source
const (
	TypeSInf = iota
	TypeSData
)

Variables

View Source
var ConfigFile string

*

如果是相对位置,则是相对执行文件的位置
View Source
var ObjectRoot string
View Source
var TempRoot string

Functions

func ConfigParse

func ConfigParse(serverType ServerType)

serverType TypeSInf interface server TypeSData data server

func Flags

func Flags(serverType ServerType)

func Init

func Init()

Types

type SData

type SData struct {
	*SPub          `yaml:"public"`
	LISTEN_ADDRESS string `yaml:"listen_address"`
	STORAGE_ROOT   string `yaml:"storage_root"`
}
var ServerData *SData

type SInf

type SInf struct {
	*SPub          `yaml:"public"`
	LISTEN_ADDRESS string `yaml:"listen_address"`
}
var ServerInf *SInf

type SPub

type SPub struct {
	ES_SERVER       string `yaml:"es_server"`
	RABBITMQ_SERVER string `yaml:"rabbitmq_server"`
}
var Pub *SPub

type ServerType

type ServerType = int

Jump to

Keyboard shortcuts

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