Documentation ¶
Overview ¶
Package serverconfig resolves shared configuration for Go Discovery services.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func GetEnv ¶
GetEnv looks up the given key from the environment, returning its value if it exists, and otherwise returning the given fallback value.
func GetEnvInt ¶
GetEnvInt looks up the given key from the environment and expects an integer, returning the integer value if it exists, and otherwise returning the given fallback value. If the environment variable has a value but it can't be parsed as an integer, GetEnvInt terminates the program.
func Init ¶
Init resolves all configuration values provided by the config package. It must be called before any configuration values are used.
func OnAppEngine ¶
func OnAppEngine() bool
OnAppEngine reports if the current process is running in an AppEngine environment.
func OnGCP ¶
func OnGCP() bool
OnGCP reports whether the current process is running on Google Cloud Platform.
func ValidateAppVersion ¶
ValidateAppVersion validates that appVersion follows the expected format defined by AppVersionFormat.
Types ¶
This section is empty.