This is the project for the website of LambdaX, both client and server. It has been completely written in Clojure(Script) and employs the following libs, whose authors we will always be grateful to:
- component
- twitter-api
- overtone At-at
- environ
- transit
- clj-time
- httpkit
- bidi
- cider-nrepl
- om.next
- ...and more
In order to generate the artifact, execute lein uberjar
.
This will create target/lambdax-web-standalone.jar
that can be launched in a script:
# export LAMBDAX_WEB_PORT=3000 # default for Prod is 3001
# export LAMBDAX_WEB_NREPL_PORT=45555 # default is 0, aka auto selection
# export LAMBDAX_WEB_FETCH_EVERY= # default 3600000 (in milliseconds)
export LAMBDAX_WEB_VERSION=0.1.0-SNAPSHOT # not shown unless specified with this variable
java -jar target/lambdax-web-standalone.jar
Note that the config.clj
in the project for prod is under "env/prod/clj".
The classic lein repl
works but you can also use nohup lein bg-repl
(logs to repl.err/out).
Note that the lambdax-web.config
namespace in env/dev/clj
contains the
default configuration and can be further customized using the above environment
variables.
To create a production build run (where |
is or):
boot -e flavor=frontend|backend build -t prod|dev
And you will find the build in target
ready to be deployed as it is.
To get an interactive development environment run:
boot -e flavor=frontend|backend dev
or for including cider/refactor-nrepl middleware:
boot -e flavor=frontend|backend cider dev
and open your browser at localhost:3000. This will auto compile and send all changes to the browser without the need to reload. After the compilation process is complete, you will get a Browser Connected REPL. An easy way to try it is:
(js/alert "Am I connected?")
and you should see an alert in the browser window.
Copyright © 2016
Distributed under the Eclipse Public License either version 1.0 or (at your option) any later version.