utils

package
v0.0.0-...-171d8e8 Latest Latest
Warning

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

Go to latest
Published: May 2, 2023 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func DBConnectionURL

func DBConnectionURL(driver, host, username, password, dbname string, port int, sslMode ...bool) (string, error)

Returns a connection url for the specified database driver build from the given parameters. Supported drivers are:

postgres
mysql

Set sslMode = "" when using MySQL

Returns an error if the type is not supported

func StartServer

func StartServer(a *fiber.App, host string, port int)

Starts the given Fiber app.

func StartWithGracefulShutdown

func StartWithGracefulShutdown(app *fiber.App, host string, port int)

Starts the given Fiber app and shuts it down gracefully if an OS Interrupt occurs.

Types

This section is empty.

Jump to

Keyboard shortcuts

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