Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func DefaultConfigDirectory ¶
func DefaultConfigDirectory() string
func DefaultConfigFile ¶
func DefaultConfigFile() string
Types ¶
type ClientConfig ¶
type ClientConfig struct {
Host string `mapstructureL:"host"`
}
type Config ¶
type Config struct { Http *Http `mapstructure:"http"` Storage *StorageConfig `mapstructure:"storage"` Db *DatabaseConfig `mapstructure:"db"` Client *ClientConfig `mapstructure:"client"` }
func LoadConfigFromViper ¶
type DatabaseConfig ¶
type DatabaseConfig struct { Type string `mapstructure:"type" default:"postgres"` Postgres *PostgresDatabaseConfig `mapstructure:"postgres"` }
type PostgresDatabaseConfig ¶
type PostgresDatabaseConfig struct { Host string `mapstructure:"host"` Port uint16 `mapstructure:"port" default:"5432"` Username string `mapstructure:"username" default:"postgres"` Password string `mapstructure:"password" default:"postgres"` Database string `mapstructure:"database" default:"default"` SslMode string `mapstructure:"sslmode" default:"disable"` }
type S3StorageConfig ¶
type StorageConfig ¶
type StorageConfig struct { Type string `mapstructure:"type" default:"s3"` S3 *S3StorageConfig `mapstructure:"s3"` }
Click to show internal directories.
Click to hide internal directories.