config

package
v0.0.0-...-43985c0 Latest Latest
Warning

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

Go to latest
Published: May 4, 2023 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 Config

type Config struct {
	Environment string        `mapstructure:"env"`
	Server      ServerConfig  `mapstructure:"server"`
	MongoDb     MongoDbConfig `mapstructure:"mongodb"`
}

func GetConfiguration

func GetConfiguration() (*Config, error)

type MongoDbConfig

type MongoDbConfig struct {
	Srv                    bool   `mapstructure:"srv"`
	Host                   string `mapstructure:"host"`
	AuthenticationDatabase string `mapstructure:"authentication-database"`
	User                   string `mapstructure:"user"`
	Password               string `mapstructure:"password"`
	Database               string `mapstructure:"database"`
	ReplicaSet             string `mapstructure:"replica-set"`
	Uri                    string
}

type ServerConfig

type ServerConfig struct {
	Host string `mapstructure:"host"`
	Port string `mapstructure:"port"`
}

Jump to

Keyboard shortcuts

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