database

package module
v0.0.0-...-83f04d7 Latest Latest
Warning

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

Go to latest
Published: Mar 24, 2024 License: MIT Imports: 3 Imported by: 0

Documentation

Index

Constants

View Source
const (
	PostgreSQLName = "postgres"
)

Variables

This section is empty.

Functions

func ConnectToDB

func ConnectToDB(ctx context.Context, cfg DatabaseConfig) (*sqlx.DB, error)

Types

type DatabaseConfig

type DatabaseConfig struct {
	Host     string `yaml:"host"`
	Port     string `yaml:"port"`
	Name     string `yaml:"name"`
	User     string `yaml:"user"`
	Password string `yaml:"password"`
	Database string `yaml:"database"`
}

Jump to

Keyboard shortcuts

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