Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Config ¶
type Config struct { Env environment `mapstructure:"ENV"` Debug bool `mapstructure:"DEBUG"` Port int `mapstructure:"PORT"` SecretKey string `mapstructure:"SECRET_KEY"` EncryptionKey string `mapstructure:"ENCRYPTION_KEY"` DatabaseURL string `mapstructure:"DATABASE_URL"` RedisURL string `mapstructure:"REDIS_URL"` }
Config represents the environment configuration.
func MustLoad ¶
func MustLoad() *Config
MustLoad ensures that a new env.Config struct is loaded and panics if not.
func (*Config) IsDevelopment ¶
IsDevelopment returns whether Config represents a development environment.
func (*Config) IsProduction ¶
IsProduction returns whether Config represents a production environment.
Click to show internal directories.
Click to hide internal directories.