Running a liberator server from a standalone jar

56 views
Skip to first unread message

Kevin Baldor

unread,
Jun 15, 2016, 12:10:06 PM6/15/16
to Liberator
Is there a way to compile a liberator-based application into a standalone jar that can be invoked with

java -jar liberator-tutorial-0.1.0-SNAPSHOT-standalone.jar <some specific main?>

I created the standalone jar with

lien uberjar

but when I try the java command above (without a main class argument), I get a REPL.

Phill Wolf

unread,
Jun 15, 2016, 7:34:14 PM6/15/16
to Liberator
Have a look at https://github.com/technomancy/leiningen/blob/master/doc/TUTORIAL.md#uberjar regarding how to configure the Leiningen project.clj for making an uberjar.

Kevin Baldor

unread,
Jun 15, 2016, 9:59:54 PM6/15/16
to Liberator
Thank you, that helped. 

There were a few other things that I needed from http://darrennewton.com/2015/03/08/sour-mash-getting-your-clojure-into-a-jar/, but your link reminded me to use 'lein uberjar' instead of 'lein ring uberjar' (which I had found elsewhere).
Reply all
Reply to author
Forward
0 new messages