config

package
v0.0.0-...-a051c0a Latest Latest
Warning

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

Go to latest
Published: Jun 2, 2024 License: MIT Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Config

type Config struct {
	StartTimeout time.Duration `yaml:"start_timeout"`
	StopTimeout  time.Duration `yaml:"stop_timeout"`
	Env          string        `yaml:"env"`
	UseCase      UseCaseConfig `yaml:"use_case"`
	GRPC         GRPCConfig    `yaml:"grpc"`
	Postgres     pg.Config     `yaml:"postgres"`
	Redis        rd.Config     `yaml:"redis"`
}

func LoadConfig

func LoadConfig() *Config

type GRPCConfig

type GRPCConfig struct {
	Host    string        `yaml:"host"`
	Port    int           `yaml:"port"`
	Timeout time.Duration `yaml:"timeout"`
}

type UseCaseConfig

type UseCaseConfig struct {
	Secret   string        `yaml:"secret"`
	TokenTTL time.Duration `yaml:"token_ttl"`
}

Jump to

Keyboard shortcuts

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