osenv

package
v0.0.0-...-f19ae85 Latest Latest
Warning

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

Go to latest
Published: Mar 12, 2015 License: AGPL-3.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

View Source
const (
	JujuEnvEnvKey           = "JUJU_ENV"
	JujuHomeEnvKey          = "JUJU_HOME"
	JujuRepositoryEnvKey    = "JUJU_REPOSITORY"
	JujuLoggingConfigEnvKey = "JUJU_LOGGING_CONFIG"
	JujuFeatureFlagEnvKey   = "JUJU_DEV_FEATURE_FLAGS"
	// TODO(thumper): 2013-09-02 bug 1219630
	// As much as I'd like to remove JujuContainerType now, it is still
	// needed as MAAS still needs it at this stage, and we can't fix
	// everything at once.
	JujuContainerTypeEnvKey = "JUJU_CONTAINER_TYPE"
)

Variables

This section is empty.

Functions

func FeatureFlags

func FeatureFlags() map[string]string

FeatureFlags returns a map that can be merged with os.Environ.

func IsJujuHomeSet

func IsJujuHomeSet() bool

IsJujuHomeSet is a way to check if SetJuuHome has been called.

func JujuHome

func JujuHome() string

JujuHome returns the current juju home.

func JujuHomeDir

func JujuHomeDir() string

JujuHomeDir returns the directory where juju should store application-specific files

func JujuHomePath

func JujuHomePath(names ...string) string

JujuHomePath returns the path to a file in the current juju home.

func MergeEnvironment

func MergeEnvironment(current, newValues map[string]string) map[string]string

MergeEnvironment will return the current environment updated with all the values from newValues. If current is nil, a new map is created. If current is not nil, it is mutated.

func SetJujuHome

func SetJujuHome(newJujuHome string) string

SetJujuHome sets the value of juju home and returns the current one.

Types

This section is empty.

Jump to

Keyboard shortcuts

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