config

package
v0.0.0-...-7b7735e Latest Latest
Warning

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

Go to latest
Published: Mar 28, 2024 License: MIT Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func DatabaseInit

func DatabaseInit(db Database, env Env)

func GracefulShutdown

func GracefulShutdown(env Env, e *echo.Echo, db Database)

Types

type Database

type Database interface {
	// contains filtered or unexported methods
}

type Env

type Env struct {
	Address  string
	Postgres string
	Mongo    string
	Secret   string
	Sender   auth.EmailSender
}

func SetEnv

func SetEnv() Env

enviroment variables setup

type MongoDB

type MongoDB struct {
	MongoDatabase *mongo.Database
	Client        *mongo.Client
}

type Postgres

type Postgres struct {
	Gorm *gorm.DB
}

func (*Postgres) Migrate

func (pg *Postgres) Migrate()

Jump to

Keyboard shortcuts

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