serve

package
v0.0.2 Latest Latest
Warning

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

Go to latest
Published: Dec 22, 2019 License: Apache-2.0 Imports: 37 Imported by: 0

Documentation

Index

Constants

View Source
const BearerPrefix = "bearer "

Variables

This section is empty.

Functions

func Run

func Run(ctx context.Context, env *cli.Environment, cfg *Config) error

Types

type Config

type Config struct {
	ListenAddr string

	// SubjectAltNames to use on server certificate
	Names san.Names

	// Enable /issue endpoint for N times.
	IssueHttp int

	// Enable node bootstrapping with given token.
	Bootstrap string

	// Auto shutdown the server after specified time if specified.
	AutoShutdown time.Duration
}

func DefaultConfig

func DefaultConfig() (*Config, error)

type Server

type Server struct {
	// contains filtered or unexported fields
}

func StartServer

func StartServer(env *cli.Environment, cfg *Config) (*Server, error)

func (*Server) Close

func (s *Server) Close(err error) error

func (*Server) Wait

func (s *Server) Wait() error

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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