{:deps {com.wagoe/wagoe-config {:mvn/version "1.0.0-beta-6"}}}
Loads resources/conf/<env>/config.edn through Aero and exposes the settings
libraries need. Assembling an Integrant system from those settings is your
application’s job, not this library’s.
{:deps {com.wagoe/wagoe-config {:mvn/version "1.0.0-beta-6"}}}
| Namespace | Purpose |
|---|---|
|
|
(require '[wagoe.config :as config])
(def cfg (config/load-config)) ; reads conf/<WAG_ENV>/config.edn
(config/db-spec cfg) ; => {:adapter :sqlite :database-path "app.db" ...}
(config/http-config cfg)
(config/logging-config cfg)
load-config resolves the profile from WAG_ENV, accepting both the long and
short spellings — production and prod name the same directory.
| Function | Reads |
|---|---|
| The active database. Exactly one of |
| Port, host and server settings. |
| Application identity and the development tenant. |
| Password and profile rules for the |
| Observability adapters. Each defaults rather than throwing — an absent optional section is normal. |
Four published libraries read configuration. Until BOU-306 they did it with
requiring-resolve against a wagoe.config namespace that the monorepo and
wagoe new both happened to generate — a convention nothing declared and
nothing checked, resting in one case on a private var. Anyone assembling a
Wagoe application by hand had no such namespace at all.
Can you improve this documentation?Edit on GitHub
cljdoc builds & hosts documentation for Clojure/Script libraries
| Ctrl+k | Jump to recent docs |
| ← | Move to previous article |
| → | Move to next article |
| Ctrl+/ | Jump to the search field |