config

package
v0.0.0-...-5122af3 Latest Latest
Warning

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

Go to latest
Published: Nov 20, 2022 License: MIT Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type BalanceClient

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

type Config

type Config struct {
	Server        Server        `yaml:"server"`
	Database      DB            `yaml:"db"`
	Redis         Redis         `yaml:"redis"`
	BalanceClient BalanceClient `yaml:"balanceClient"`
}

func GetConfigYML

func GetConfigYML(configYML string) *Config

type DB

type DB struct {
	Host     string `yaml:"host"`
	Port     int    `yaml:"port"`
	Username string `yaml:"user"`
	Password string `yaml:"password"`
	NameDB   string `yaml:"dbname"`
}

type Redis

type Redis struct {
	Host       string        `yaml:"host"`
	Port       string        `yaml:"port"`
	Password   string        `yaml:"password"`
	SessionTTL time.Duration `yaml:"sessionTTL"` //nolint:tagliatelle
}

type Server

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

Jump to

Keyboard shortcuts

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