configs

package
v0.0.0-...-faa9808 Latest Latest
Warning

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

Go to latest
Published: Apr 24, 2023 License: MIT Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func LoadEnv

func LoadEnv()

Types

type AppConfig

type AppConfig struct {
	AppName          string `mapstructure:"APP_NAME"`
	AppDebug         bool   `mapstructure:"APP_DEBUG"`
	AppVersion       string `mapstructure:"APP_VERSION"`
	AppURL           string `mapstructure:"APP_URL"`
	PokeapiURL       string `mapstructure:"POKEAPI_URL"`
	DBDriver         string `mapstructure:"DB_DRIVER"`
	DBDsnURL         string `mapstructure:"DB_DSN_URL"`
	LastSync         int64  `mapstructure:"LAST_SYNC"`
	LimitSync        int    `mapstructure:"LIMIT_SYNC"`
	LastMonsterID    int    `mapstructure:"LAST_MONSTER_ID"`
	TotalMonsterSync int    `mapstructure:"TOTAL_MONSTER_SYNC"`
}
var (
	Instance *AppConfig

	DbPool *sql.DB
)

func (*AppConfig) InitDbConn

func (cfg *AppConfig) InitDbConn()

func (*AppConfig) UpdateEnv

func (cfg *AppConfig) UpdateEnv(key, value any)

Jump to

Keyboard shortcuts

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