config

package
v0.0.0-...-5dd2f1f Latest Latest
Warning

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

Go to latest
Published: Dec 9, 2023 License: Apache-2.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func LoadConfig

func LoadConfig(filePath string)

LoadConfig loads the configuration from a specified YAML file path.

Types

type ApolloUser

type ApolloUser struct {
	ID       int    `json:"id"`
	Name     string `json:"name"`
	Email    string `json:"email"`
	UserType string `json:"userType"`
}

AUTHBOSS INTERFACES

type AssetsConfig

type AssetsConfig struct {
	Img string `yaml:"images"`
	CSS string `yaml:"css"`
	JS  string `yaml:"js"`
}

AssetsConfig armazena as configurações de ativos.

type Config

type Config struct {
	Assets       AssetsConfig       `yaml:"assets"`
	StaticConfig StaticConfig       `yaml:"static_config"`
	Templates    TemplatesConfig    `yaml:"templates"`
	Database     DatabaseConfig     `yaml:"database"`
	ServerConfig ServerConfig       `yaml:"server"`
	LogConfig    LogConfig          `yaml:"log"`
	Localization LocalizationConfig `yaml:"localization"`
}

Config armazena as configurações do aplicativo.

func GetConfig

func GetConfig() *Config

GetConfig returns the global configuration

type DatabaseConfig

type DatabaseConfig struct {
	User     string `yaml:"user"`
	Password string `yaml:"password"`
	Host     string `yaml:"host"`
	Port     string `yaml:"port"`
	Name     string `yaml:"name"`
}

DatabaseConfig armazena as configurações do banco de dados.

type LocalizationConfig

type LocalizationConfig struct {
	LocalesPath string `yaml:"locales_path"`
}

type LogConfig

type LogConfig struct {
	LogLevel    string `yaml:"logLevel"`
	LogPath     string `yaml:"logPath"`
	MaxSizeMB   int    `yaml:"maxSizeMB"`
	MaxBackups  int    `yaml:"maxBackups"`
	MaxAgeDays  int    `yaml:"maxAgeDays"`
	LogToStdout bool   `yaml:"logToStdout"`
}

type LoginRequest

type LoginRequest struct {
	Email    string `JSON:"email"`
	Password string `JSON:"password"`
}

type ServerConfig

type ServerConfig struct {
	Port string `yaml:"port"`
}

type StaticConfig

type StaticConfig struct {
	Path   string `yaml:"path"`
	Prefix string `yaml:"prefix"`
}

StaticConfig armazena as configurações estáticas.

type TemplatesConfig

type TemplatesConfig struct {
	Path string `yaml:"path"`
}

Jump to

Keyboard shortcuts

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