devgo

package module
v0.0.3 Latest Latest
Warning

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

Go to latest
Published: May 12, 2024 License: MIT Imports: 12 Imported by: 0

README

dev-go

// .env

DEVGODB="host=host user=user password=pass dbname=dbname port=port sslmode=disable"
SECRET=<secret_key> 
DEBUG=<Either true or false>
// main.go

func init() {
	devgo.Config()
	devgo.ConnectToDb()
	devgo.SyncDatabase()
}

...
func main() {
	devgo.DevGoServer.ListenAndServe()
}

Documentation

Index

Constants

This section is empty.

Variables

View Source
var DevGoServer = &http.Server{
	Addr:         ":3000",
	Handler:      devgoRouter(),
	ReadTimeout:  5 * time.Second,
	WriteTimeout: 10 * time.Second,
}

Functions

func Config

func Config()

func ConnectToDb

func ConnectToDb()

func SyncDatabase

func SyncDatabase()

Types

This section is empty.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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