Documentation ¶
Index ¶
Constants ¶
View Source
const ( EnvironmentVariableName = "ECHO_ENV" Development = "development" Test = "test" Production = "production" )
Variables ¶
View Source
var DB *gorm.DB
DB is the connection pool of Postgres database
View Source
var Log = logrus.New()
Log is an instance of Logrus logger
Functions ¶
func DatabaseName ¶
func DatabaseName() string
Types ¶
type Config ¶
type Config struct { Version string `env:"APP_VERSION"` DatabasePool int `env:"BREIZHTRIP_DATABASE_POOL" envDefault:"20"` DatabaseHost string `env:"BREIZHTRIP_DATABASE_HOST" envDefault:"localhost"` DatabasePort string `env:"BREIZHTRIP_DATABASE_PORT" envDefault:"5432"` DatabaseUsername string `env:"BREIZHTRIP_DATABASE_USERNAME" envDefault:"postgres"` DatabasePassword string `env:"BREIZHTRIP_DATABASE_PASSWORD" envDefault:"postgres"` }
Config holds all configuration for our program
var Cfg *Config
Click to show internal directories.
Click to hide internal directories.