config

package
v0.3.1 Latest Latest
Warning

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

Go to latest
Published: Jun 19, 2022 License: Zlib Imports: 5 Imported by: 3

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	Version       = "1.0.0"
	AppName       = "unknown"
	SeqId   int64 = 0
	Source  string
)
View Source
var (
	WorkDir string
	Conf    string
	Env     = "prod"
)

Functions

func ConfFileName

func ConfFileName() string

func ConfigureFileNameInEnv

func ConfigureFileNameInEnv(name string) string

func IsRelease

func IsRelease() bool

Types

type Config

type Config struct {
	GinMode      string        `json:"mode"`
	Server       string        `json:"server"`
	PubIP        string        `json:"public_ip"`
	EnabledUser  bool          `json:"enabled_user"`
	EnabledRedis bool          `json:"enabled_redis"`
	EnabledDb    bool          `json:"enabled_db"`
	EnabledId    bool          `json:"enabled_id"`
	EnabledMQ    bool          `json:"enabled_mq"`
	LogConfig    logger.Config `json:"log"`
}

func (*Config) Init

func (cfg *Config) Init()

Jump to

Keyboard shortcuts

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