Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ( // ErrMissingEnvironmentStage missing stage configuration. ErrMissingEnvironmentStage = errors.New("Missing Stage ENV Variable") // ErrMissingEnvironmentBranch missing branch configuration. ErrMissingEnvironmentBranch = errors.New("Missing Branch ENV Variable") )
Functions ¶
This section is empty.
Types ¶
type Config ¶
type Config struct { Debug bool `envconfig:"DEBUG"` Addr string `envconfig:"ADDR" default:":8080"` Stage string `envconfig:"STAGE" default:"dev"` Branch string `envconfig:"BRANCH"` PGDatasource string `envconfig:"PGDATASOURCE"` OpenIDProvider string `envconfig:"OPENID_PROVIDER_URL"` ClientID string `envconfig:"OAUTH_CLIENT_ID"` MetricsWriteInterval int `envconfig:"METRICS_WRITE_INTERVAL"` DbSecrets string `envconfig:"DB_SECRET"` }
Config for the environment.
func NewDefaultConfig ¶
NewDefaultConfig reads configuration from environment variables and validates it.
Click to show internal directories.
Click to hide internal directories.