configs

package
v0.0.0-...-93e8ec0 Latest Latest
Warning

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

Go to latest
Published: Nov 30, 2023 License: AGPL-3.0 Imports: 3 Imported by: 0

Documentation

Overview

Package configs contains configuration structs.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Config

type Config struct {
	WebAPI
	Logger
	GRPC
}

Config contains configs of all app layers.

func NewConfig

func NewConfig(configPath string) (*Config, error)

NewConfig returns app config.

type GRPC

type GRPC struct {
	IP             string `toml:"tcp_ip"`
	Port           string `toml:"tcp_port"`
	MaxClients     int    `toml:"max_clients"`
	NumPoolWorkers uint32 `toml:"num_pool_workers"`
}

GRPC contains info for gRPC server configuration.

type Logger

type Logger struct {
	Format          string   `toml:"log_format"`
	Level           string   `toml:"log_level"`
	EncoderType     string   `toml:"encoder_type"`
	OutputPath      []string `toml:"output_path"`
	ErrorOutputPath []string `toml:"error_output_path"`
}

Logger contains info for logger configuration.

type WebAPI

type WebAPI struct {
	IP           string `toml:"web_api_ip"`
	Port         string `toml:"web_api_port"`
	Login        string `toml:"login"`
	Password     string `toml:"password"`
	ProtocolType string `toml:"protocol_type"`
	EmployeePath string `toml:"employee_path"`
	AbsencePath  string `toml:"absence_path"`
}

WebAPI contains info for WebAPI configuration.

Jump to

Keyboard shortcuts

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