internalserver

package
v0.0.0-...-7251252 Latest Latest
Warning

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

Go to latest
Published: Feb 7, 2023 License: AGPL-3.0 Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Handler

func Handler(logger log.Logger, cfg Config) (run func() error, stop func(error))

Types

type Config

type Config struct {
	HTTPListenAddress             string        `yaml:"http_listen_address"`
	HTTPListenPort                int           `yaml:"http_listen_port"`
	ServerGracefulShutdownTimeout time.Duration `yaml:"graceful_shutdown_timeout"`
}

Config for the Internal Server

func (*Config) RegisterFlags

func (cfg *Config) RegisterFlags(flags *flag.FlagSet)

RegisterFlags adds the flags required to config this to the given FlagSet

func (*Config) RegisterFlagsWithPrefix

func (cfg *Config) RegisterFlagsWithPrefix(prefix string, flags *flag.FlagSet)

RegisterFlagsWithPrefix registers flags, adding the provided prefix if needed. If the prefix is not blank and doesn't end with '.', a '.' is appended to it.

Jump to

Keyboard shortcuts

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