$ go get github.com/innotechdevops/mgo-driver
- Wtih env
driver := mgodriver.New(mgodriver.ConfigEnv())
- With config
driver := mgodriver.New(mgodriver.Config{
User: os.Getenv("MARIA_USER"),
Pass: os.Getenv("MARIA_PASS"),
Host: os.Getenv("MARIA_HOST"),
DatabaseName: os.Getenv("MARIA_DATABASE"),
Port: mgodriver.DefaultPort,
})