Documentation ¶
Index ¶
- func Get(e EnvironmentVariable) string
- func GetBoolean(e EnvironmentVariable) (bool, error)
- func GetBooleanOr(e EnvironmentVariable, fallback bool) bool
- func GetDuration(e EnvironmentVariable) (time.Duration, error)
- func GetDurationOr(e EnvironmentVariable, fallback time.Duration) (time.Duration, error)
- func GetEmail(e EnvironmentVariable) (string, error)
- func GetInt(e EnvironmentVariable) (int, error)
- func GetOr(e EnvironmentVariable, fallback string) string
- func GetUUID(e EnvironmentVariable) (id uuid.UUID, err error)
- func GetUint(e EnvironmentVariable) (uint, error)
- type EnvironmentVariable
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func Get ¶
func Get(e EnvironmentVariable) string
func GetBoolean ¶
func GetBoolean(e EnvironmentVariable) (bool, error)
func GetBooleanOr ¶
func GetBooleanOr(e EnvironmentVariable, fallback bool) bool
func GetDuration ¶
func GetDuration(e EnvironmentVariable) (time.Duration, error)
func GetDurationOr ¶
func GetEmail ¶
func GetEmail(e EnvironmentVariable) (string, error)
func GetInt ¶
func GetInt(e EnvironmentVariable) (int, error)
func GetOr ¶
func GetOr(e EnvironmentVariable, fallback string) string
func GetUint ¶
func GetUint(e EnvironmentVariable) (uint, error)
Types ¶
type EnvironmentVariable ¶
type EnvironmentVariable string
const ( LogLevel EnvironmentVariable = "LOG_LEVEL" RedisURL EnvironmentVariable = "REDIS_URL" APIPort EnvironmentVariable = "API_PORT" APIVer EnvironmentVariable = "API_VER" APIBase EnvironmentVariable = "API_BASE" Stage EnvironmentVariable = "STAGE" AppName EnvironmentVariable = "APP_NAME" AppSecret EnvironmentVariable = "APP_SECRET" AdminEmail EnvironmentVariable = "ADMIN_EMAIL" AdminPass EnvironmentVariable = "ADMIN_PASSWORD" )
func (EnvironmentVariable) String ¶
func (e EnvironmentVariable) String() string
Click to show internal directories.
Click to hide internal directories.