config

package
v0.0.0-...-6e892aa Latest Latest
Warning

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

Go to latest
Published: Apr 25, 2025 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 {
	Server struct {
		GRPCAddr  string `yaml:"grpc_addr"`
		HTTPAddr  string `yaml:"http_addr"`
		LogLevel  string `yaml:"log_level"`
		LogFormat string `yaml:"log_format"`
	} `yaml:"server"`

	Redis struct {
		Addr     string `yaml:"addr"`
		Password string `yaml:"password"`
		DB       int    `yaml:"db"`
	} `yaml:"redis"`

	Kafka struct {
		BrokerAddr string `yaml:"broker_addr"`
		Topic      string `yaml:"topic"`
	} `yaml:"kafka"`
}

Config represents the application configuration

func LoadConfig

func LoadConfig() (*Config, error)

LoadConfig loads the configuration from command line flags and optionally from a config file

Jump to

Keyboard shortcuts

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