goapp

package
v0.1.0 Latest Latest
Warning

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

Go to latest
Published: Nov 9, 2020 License: BSD-3-Clause Imports: 10 Imported by: 35

Documentation

Index

Constants

This section is empty.

Variables

View Source
var Config = viper.New()

Config is a viper based application config

View Source
var Log = logrus.New()

Log is applications logger

Functions

func InitConfig

func InitConfig(configFile string) error

InitConfig tries to load config.yml from exe's dir

func InitEnv

func InitEnv(config *viper.Viper)

InitEnv initializes viper for environment variables

func StartWithDefault

func StartWithDefault()

StartWithDefault default app initialization function Tries to load config from commandline option '-c' panics on error

func StartWithFlags

func StartWithFlags(fs *flag.FlagSet, args []string)

StartWithFlags app initialization function with flagset panics on error

func Sub

func Sub(config *viper.Viper, name string) *viper.Viper

Sub extracts Sub config from viper using env variables

Types

This section is empty.

Jump to

Keyboard shortcuts

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