config

package
v0.0.1-alpha-rc2 Latest Latest
Warning

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

Go to latest
Published: Nov 25, 2021 License: MIT Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ApiConfig

type ApiConfig interface {
	Port() string
}

func NewApiConfig

func NewApiConfig(env *viper.Viper) ApiConfig

type AppConfig

type AppConfig interface {
	BuildEnv() string
}

func NewAppConfig

func NewAppConfig(env *viper.Viper) AppConfig

type Configuration

type Configuration interface {
	AppConfig() AppConfig
	ApiConfig() ApiConfig
	PostgresConfig() PostgresConfig
	GrpcConfig() GrpcConfig
	QueueConfig() QueueConfig
}

func Init

func Init(
	v *viper.Viper,
) Configuration

type GrpcConfig

type GrpcConfig interface {
	Port() string
}

func NewGrpcConfig

func NewGrpcConfig(env *viper.Viper) GrpcConfig

type PostgresConfig

type PostgresConfig interface {
	Host() string
	Port() string
	Database() string
	User() string
	Password() string
	ConnectionURL() string
}

func NewPostgresConfig

func NewPostgresConfig(env *viper.Viper) PostgresConfig

type QueueConfig

type QueueConfig interface {
	NatsClientName() string
	NatsURL() string
	NatsUsername() string
	NatsPassword() string
}

func NewQueueConfig

func NewQueueConfig(env *viper.Viper) QueueConfig

Jump to

Keyboard shortcuts

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