Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Config ¶
type Config struct { fx.Out DB DBConfig `mapstructure:"db"` LLM LLMConfig `mapstructure:"llm"` Server ServerConfig `mapstructure:"server"` }
func NewConfig ¶
func NewConfig() Config
NewConfig returns a new Config instance with values loaded from environment variables.
func NewTestConfig ¶
func NewTestConfig() Config
NewTestConfig returns a Config instance intended for testing. TODO: assign random available ports to avoid conflicts with other tests.
type DBConfig ¶
type DBConfig struct {
URL string `mapstructure:"url"`
}
func (DBConfig) MigrationsDir ¶
type ServerConfig ¶
type ServerConfig struct { Host string `mapstructure:"host"` RESTPort int `mapstructure:"rest_port"` GRPCPort int `mapstructure:"grpc_port"` ReadTimeout time.Duration `mapstructure:"read_timeout"` WriteTimeout time.Duration `mapstructure:"write_timeout"` JWTSecret string `mapstructure:"jwt_secret"` }
func (ServerConfig) GRPCAddress ¶
func (c ServerConfig) GRPCAddress() string
func (ServerConfig) OAPISchemaDir ¶
func (c ServerConfig) OAPISchemaDir() string
func (ServerConfig) RESTAddress ¶
func (c ServerConfig) RESTAddress() string
Click to show internal directories.
Click to hide internal directories.