common

package
v0.0.0-...-3bf928b Latest Latest
Warning

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

Go to latest
Published: Jan 13, 2023 License: MIT Imports: 7 Imported by: 0

Documentation

Index

Constants

View Source
const (
	HOST = "database"
	PORT = 5432
)

Variables

This section is empty.

Functions

func CreateContext

func CreateContext(args *CustomContext, next http.Handler) http.Handler

func InitDb

func InitDb(username, password, database string) (*gorm.DB, error)

Types

type CustomContext

type CustomContext struct {
	Database *gorm.DB
}

func GetContext

func GetContext(ctx context.Context) *CustomContext

Jump to

Keyboard shortcuts

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