boot

package
v0.0.0-...-c98e0de Latest Latest
Warning

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

Go to latest
Published: Aug 31, 2024 License: MIT Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ExecuteMigrations

func ExecuteMigrations()

func LoadConfig

func LoadConfig()

Types

type ApplicationConf

type ApplicationConf struct {
	Name string `yaml:"name"`
	Env  string `yaml:"environment"`
}

type Configuration

type Configuration struct {
	Application ApplicationConf `yaml:"app"`
	Security    SecurityConf    `yaml:"security"`
	Data        DataConf        `yaml:"data"`
	Server      ServerConf      `yaml:"server"`
}
var CONFIG Configuration

type DataConf

type DataConf struct {
	Datasource DatasourceConf `yaml:"datasource"`
}

type DatasourceConf

type DatasourceConf struct {
	Postgres PostgresConf `yaml:"postgres"`
}

type JWTConf

type JWTConf struct {
	Secret     string        `yaml:"secret"`
	Expiration time.Duration `yaml:"expiration"`
}

type PasswordConfig

type PasswordConfig struct {
	Cost int `yaml:"cost"`
}

type PostgresConf

type PostgresConf struct {
	Host     string `yaml:"host"`
	Port     int    `yaml:"port"`
	User     string `yaml:"user"`
	Password string `yaml:"password"`
	Database string `yaml:"database"`
}

type SecurityConf

type SecurityConf struct {
	JWT      JWTConf        `yaml:"jwt"`
	Password PasswordConfig `yaml:"password"`
}

type ServerConf

type ServerConf struct {
	Port         int           `yaml:"port"`
	ReadTimeout  time.Duration `yaml:"read-timeout"`
	WriteTimeout time.Duration `yaml:"write-timeout"`
}

Jump to

Keyboard shortcuts

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