Discover Packages
github.com/edwinvautier/go-bot
conf
package
Version:
v0.0.0-...-ee611d5
Opens a new window with list of versions in this module.
Published: Dec 7, 2020
License: MIT
Opens a new window with license information.
Imports: 4
Opens a new window with list of imports.
Imported by: 0
Opens a new window with list of known importers.
Documentation
Documentation
¶
InitializeDb takes the database connection information as arguments .
Creates a connection to the db and set the connection to the pointer Db *gorm.DB .
MakeMigrations auto migrate the passed models.
type DbConfig struct {
DbUser string `env:"DB_USER"`
DbPassword string `env:"DB_PASSWORD"`
DbPort int `env:"DB_PORT" envDefault:"5432"`
DbHost string `env:"DB_HOST"`
DbName string `env:"DB_NAME"`
}
Source Files
¶
Click to show internal directories.
Click to hide internal directories.