Right, identified the major problem with the Tomcat config

No idea yet how to fix it, and in the meantime many things that were solid have become broken.
This commit is contained in:
Simon Brooke 2021-03-23 15:55:31 +00:00
parent 9ca1cc05ab
commit 11840acdde
No known key found for this signature in database
GPG key ID: A7A4F18D1D4DF987

View file

@ -56,6 +56,11 @@
{} {}
vars)) vars))
;;; TODO: OK, why this doesn't work. We need a namespace (and, indeed, ideally
;;; in a library) which returns the name/value pairs of the InitialContext as
;;; a map. We need this because, if the config file itself is to be specified
;;; in this way, we need to be able to access this map BEFORE we do build-config.
(defn- from-initial-context (defn- from-initial-context
"Config `vars` are read from the initial context, which (at least under Tomcat) "Config `vars` are read from the initial context, which (at least under Tomcat)
are specific to the individual web app. Nevertheless the same names will are specific to the individual web app. Nevertheless the same names will
@ -175,10 +180,11 @@
(transform-map (transform-map
(from-env-vars config-var-names) (from-env-vars config-var-names)
config-env-transforms) config-env-transforms)
(transform-map ;; (transform-map
(from-initial-context config-var-names) ;; (from-initial-context config-var-names)
config-env-transforms))] ;; config-env-transforms)
(if (env :dev) )]
(when (env :dev)
(log/debug (log/debug
"Loaded configuration\n" "Loaded configuration\n"
(with-out-str (clojure.pprint/pprint config)))) (with-out-str (clojure.pprint/pprint config))))