server

package
v0.10.1 Latest Latest
Warning

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

Go to latest
Published: Jun 14, 2016 License: BSD-2-Clause Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	DefaultOptions = Options{}
)

Functions

func New

func New(e *empire.Empire, options Options) httpx.Handler

Types

type HealthHandler

type HealthHandler struct {
	// A function that returns true if empire is healthy.
	IsHealthy func() bool
}

HealthHandler is an http.Handler that returns the health of empire.

func NewHealthHandler

func NewHealthHandler(e *empire.Empire) *HealthHandler

NewHealthHandler returns a new HealthHandler using the IsHealthy method from an Empire instance.

func (*HealthHandler) ServeHTTPContext

func (h *HealthHandler) ServeHTTPContext(_ context.Context, w http.ResponseWriter, r *http.Request) error

type Options

type Options struct {
	Authenticator auth.Authenticator

	GitHub struct {
		// Deployments
		Webhooks struct {
			Secret string
		}
		Deployments struct {
			Environments []string
			ImageBuilder github.ImageBuilder
			TugboatURL   string
		}
	}
}

Directories

Path Synopsis
Package auth contains types for authenticating and authorizing requests.
Package auth contains types for authenticating and authorizing requests.
github
Package github provides auth.Authentication and auth.Authorizer implementations backed by GitHub users, orgs and teams.
Package github provides auth.Authentication and auth.Authorizer implementations backed by GitHub users, orgs and teams.

Jump to

Keyboard shortcuts

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