#30: Roughly working on Tomcat.
Not perfect yet by a long way but good enough for alpha.
This commit is contained in:
parent
d31ed67b98
commit
5b35b5bc18
4 changed files with 26 additions and 5 deletions
19
env/dev/clj/user.clj
vendored
19
env/dev/clj/user.clj
vendored
|
|
@ -13,4 +13,23 @@
|
|||
(stop)
|
||||
(start))
|
||||
|
||||
;; Roughly working under Tomcat.
|
||||
;; Database setup using JNDI: see http://www.luminusweb.net/docs/deployment.md#deploying_to_tomcat
|
||||
;; Note that this duplicates configuration in profiles.clj; one of these is wrong (and neither
|
||||
;; should be in the Git repository but this is for now!)
|
||||
(System/setProperty "java.naming.factory.initial"
|
||||
"org.apache.naming.java.javaURLContextFactory")
|
||||
(System/setProperty "java.naming.factory.url.pkgs"
|
||||
"org.apache.naming")
|
||||
|
||||
(doto (new javax.naming.InitialContext)
|
||||
(.createSubcontext "java:")
|
||||
(.createSubcontext "java:comp")
|
||||
(.createSubcontext "java:comp/env")
|
||||
(.createSubcontext "java:comp/env/jdbc")
|
||||
(.bind "java:comp/env/jdbc/testdb"
|
||||
(doto (org.postgresql.ds.PGSimpleDataSource.)
|
||||
(.setServerName "localhost")
|
||||
(.setDatabaseName "youyesyet_dev")
|
||||
(.setUser "youyesyet")
|
||||
(.setPassword "thisisnotsecure"))))
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue