config

package
v1.0.2 Latest Latest
Warning

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

Go to latest
Published: Jan 8, 2024 License: MIT Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Configuration

type Configuration struct {
	Stage           string   `env:"STAGE"`
	Host            string   `env:"HOST"`
	Port            int      `env:"PORT"`
	ReadTimeout     int      `env:"READ_TIMEOUT"`
	WriteTimeout    int      `env:"WRITE_TIMEOUT"`
	AllowOrigins    []string `env:"ALLOW_ORIGINS"`
	Debug           bool     `env:"DEBUG"`
	DbLog           bool     `env:"DB_LOG"`
	DbType          string   `env:"DB_TYPE"`
	DbDsn           string   `env:"DB_DSN"`
	JwtSecret       string   `env:"JWT_SECRET"`
	JwtDuration     int      `env:"JWT_DURATION"`
	JwtAlgorithm    string   `env:"JWT_ALGORITHM"`
	IsEnableAIPDocs bool     `env:"IS_ENABLE_API_DOCS"`
	APIDocsPath     string   `env:"API_DOCS_PATH"`
}

Configuration holds data necessery for configuring application

func Load

func Load() (*Configuration, error)

Load returns Configuration struct

Jump to

Keyboard shortcuts

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