sherlock

package
v0.0.2 Latest Latest
Warning

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

Go to latest
Published: Sep 22, 2021 License: BSD-3-Clause Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	Config = viper.New()
)

package level variable holding a viper instance that will manage sherlock's config

Functions

This section is empty.

Types

type Application

type Application struct {
	Services     *services.ServiceController
	Builds       *builds.BuildController
	Environments *environments.EnvironmentController
	Handler      http.Handler
	// Used to pass the dbConn to testing setup helpers
	// without needing to instantiate a full model instance
	DB *gorm.DB
}

Application is the core application type containing a router and db connection repository is a wrapper type so we can define our own methods on the type holding the DB connection pool

func New

func New() *Application

New returns a new instance of the core sherlock application

func (*Application) ServeHTTP

func (a *Application) ServeHTTP(w http.ResponseWriter, r *http.Request)

ServeHTTP implments the http.Handler interface for a Sherlock application instance

Jump to

Keyboard shortcuts

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