configuration

package
v0.0.0-...-d158ecd Latest Latest
Warning

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

Go to latest
Published: Oct 31, 2015 License: BSD-3-Clause Imports: 4 Imported by: 0

Documentation

Index

Constants

View Source
const (
	Debug         = "Debug"
	ListenPort    = "ListenPort"
	ListenHost    = "ListenHost"
	TemplatesPath = "TemplatesPath"
	StaticURL     = "StaticUrl"
	StaticPath    = "StaticPath"
	DisableLogs   = "DisableLogs"
	LogLevel      = "LogLevel"
	SettingsPath  = "Settings" // on env var MONF_SETTINGS
)

Configuration names

Variables

View Source
var SpecificConfigPath = ""

SpecificConfigPath will be the global var to track the custom config file

Functions

func ConfigureLogs

func ConfigureLogs()

ConfigureLogs configure the logging system based on teh log settings

func LoadAppDefaultSettings

func LoadAppDefaultSettings()

LoadAppDefaultSettings loads the default settings

func LoadDefaultFilePathSettings

func LoadDefaultFilePathSettings()

LoadDefaultFilePathSettings Sets the configuration default file paths

func LoadFromFileSettings

func LoadFromFileSettings(path string)

LoadFromFileSettings loads the settings from an specified path

func LoadSettings

func LoadSettings(path string)

LoadSettings Load all the app settings If specific path then don't look at the env var, nor default places

func OverrideSettings

func OverrideSettings(settings map[string]interface{})

OverrideSettings overrides the passed ones, useful for tests

func ResetSettings

func ResetSettings()

ResetSettings resets the viper settings

Types

This section is empty.

Jump to

Keyboard shortcuts

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