Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Application ¶
type Application struct { Name string `json:"name" yaml:"name"` HTTP httpx.Options `json:"http" yaml:"http"` GRPC GRPC `json:"grpc" yaml:"grpc"` Storage struct { Mongodb struct { DSN string `json:"dsn" yaml:"dsn"` } `json:"mongodb" yaml:"mongodb"` Postgresql struct { DSN string `json:"dsn" yaml:"dsn"` } `json:"postgresql" yaml:"postgresql"` } `json:"storage" yaml:"storage"` OTel struct { Target string `json:"target" yaml:"target"` } `json:"otel" yaml:"otel"` }
Application is the application configuration.
type Configuration ¶
type Configuration struct { Log logging.Options `json:"log" yaml:"log"` Networks map[string]*Network `json:"networks" yaml:"networks"` Services map[string]*Application `json:"services" yaml:"services"` }
Configuration is the application configuration
func NewConfiguration ¶
func NewConfiguration(v *viper.Viper) (*Configuration, error)
NewConfiguration creates a new configuration.
func (*Configuration) GetService ¶
func (x *Configuration) GetService(name string) (*Application, error)
GetService is used to get the service by name.
Click to show internal directories.
Click to hide internal directories.