config

package
v2.3.0 Latest Latest
Warning

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

Go to latest
Published: Apr 21, 2026 License: Apache-2.0 Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Get

func Get(ctx context.Context, pattern string, def ...any) (*gvar.Var, error)

func GetBool

func GetBool(ctx context.Context, pattern string, def ...any) (bool, error)

func GetInt

func GetInt(ctx context.Context, pattern string, def ...any) int

func GetMapStrStr

func GetMapStrStr(ctx context.Context, pattern string, def ...any) map[string]string

func GetString

func GetString(ctx context.Context, pattern string, def ...any) string

func Reload

func Reload(ctx context.Context, sysConfig *entity.SysConfig)

Types

type Config

type Config struct {
	AdminServerAddress string `json:"admin_server_address"`
	Local              Local  `json:"local"`
	*entity.SysConfig
}

配置信息

var Cfg *Config

type Local

type Local struct {
	PublicIp []string `json:"public_ip"`
}

Jump to

Keyboard shortcuts

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