subcommands

package
v0.0.0-...-8018142 Latest Latest
Warning

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

Go to latest
Published: Feb 9, 2021 License: MPL-2.0 Imports: 4 Imported by: 2

README

subcommands

GoDoc

Documentation

Overview

Package subcommands provides all the alternative top-level functions that run one-off commands that don't run the main event loop.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GetPingHandler

func GetPingHandler(params Params) error

GetPingHandler fires a ping check through the HTTPClient.

func MaintenanceHandler

func MaintenanceHandler(params Params) error

MaintenanceHandler fires either an enable or disable SetMaintenance request through the HTTPClient.

func PutEnvHandler

func PutEnvHandler(params Params) error

PutEnvHandler fires a PutEnv request through the HTTPClient.

func PutMetricsHandler

func PutMetricsHandler(params Params) error

PutMetricsHandler fires a PutMetric request through the HTTPClient.

func ReloadHandler

func ReloadHandler(params Params) error

ReloadHandler fires a Reload request through the HTTPClient.

func RenderHandler

func RenderHandler(params Params) error

RenderHandler asks the configuration package to render the configuration to the path provided

func VersionHandler

func VersionHandler(params Params) error

VersionHandler prints the version info only

Types

type Handler

type Handler func(Params) error

Handler functions implement a subcommand

type Params

type Params struct {
	Version string
	GitHash string

	ConfigPath      string
	RenderFlag      string
	MaintenanceFlag string

	Metrics map[string]string
	Env     map[string]string
}

Params ...

Jump to

Keyboard shortcuts

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