phoenix

package module
v1.1.0 Latest Latest
Warning

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

Go to latest
Published: Aug 29, 2019 License: Apache-2.0 Imports: 7 Imported by: 0

README

Phoenix

README IS A WORK IN PROGRESS AS WE ARE WRITTING MORE DOCUMENTATION ABOUT THIS PACKAGE.

Package phoenix contains a base bahamut server that can be used to implelement an Aporeto API Hook endpoint.

Documentation

Overview

Package phoenix contains a base bahamut server that can be used to implelement an Aporeto API Hook endpoint.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewServer

func NewServer(
	pluginsRegistry HooksRegistry,
	listenAddress string,
	caPool *x509.CertPool,
	serverCertificates []tls.Certificate,
	enableHealth bool,
	healthHandlerFunc bahamut.HealthServerFunc,
	healtListenAddress string,
) bahamut.Server

NewServer returns a new phoenix server with the given hook.

Types

type BaseConfiguration

type BaseConfiguration struct {
	CAPoolPath               string `mapstructure:"cacert"              desc:"Path to the CA certificate"                   required:"true"`
	ListenAddress            string `mapstructure:"listen"              desc:"Listening address"                            default:":443"`
	ServerCertificatePath    string `mapstructure:"server-cert"         desc:"Path to the server certificate"               required:"true"`
	ServerCertificateKeyPath string `mapstructure:"server-cert-key"     desc:"Path to the server certificate key"           required:"true"`
}

BaseConfiguration represent the bare minimal configuration to get a phoenix server running

type HookFunc

HookFunc is the type of a function to that can be used as a Hook.

type HooksRegistry

type HooksRegistry []HookFunc

HooksRegistry represents a list of HookFunc.

func NewHooksRegistry

func NewHooksRegistry(plugins ...HookFunc) HooksRegistry

NewHooksRegistry returns a HooksRegistry with the given list of HookFunc.

Jump to

Keyboard shortcuts

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