envsvc

package
v0.1.0 Latest Latest
Warning

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

Go to latest
Published: Mar 7, 2018 License: MIT Imports: 6 Imported by: 0

Documentation

Overview

Package envsvc provides convenience methods for using env with services.

It exposes these variables via HTTP at /debug/env in JSON format.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Handler

func Handler() http.Handler

Handler returns the env HTTP Handler.

This is only needed to install the handler in a non-standard location.

func Parse

func Parse()

Parse registers command line arguments -env-check, -env-dump, -env-dump-yaml and calls env.Parse(). Any errors are written to stderr and then os.Exit(1) is called.

Registered flags: -env-dump: skips parsing step and writes each env.Var to stderr, calls os.Exit(0) when done. -env-dump-yaml: skips parsing steps and write each env.Var to stderr in YAML format, calls os.Exit(0) when done. -env-check: calls os.Exit(0) if env.Parse() succeeds without error.

Types

This section is empty.

Jump to

Keyboard shortcuts

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