Short story: I'm trying to deploy on tomcat7 an application built with the http-kit template here, but the third step is a command (sh java -jar target/lein-template-standalone.jar --profile prod --port 8000
) and I have absolutely no idea what to do with it.
Long story: For a simple compojure application I can just do:
$ lein new compojure-app projectX
$ cd projectx
$ lein ring uberwar
$ sudo mv target/projectx-0.1.0-SNAPSHOT-standalone.war /var/lib/tomcat7/webapps/ROOT.war
$ sudo service tomcat7 restart
...and it works. Now the http-kit template has instructions for deployment here (https://github.com/http-kit/lein-template) and it's pretty different. I removed everything in tomcat7/webapps and then:
$ lein new http-kit projectX
$ cd projectx
$ lein uberjar
$ sudo mv target/projectx-standalone.jar /var/lib/tomcat7/webapps/ROOT.jar
$ sudo cp -r public/ /var/lib/tomcat7/webapps/
$ sudo service tomcat7 restart
It doesn't work, but there's no error, my local host is blank. That's probably not surprising, the README for the http-kit template has three steps:
- lein uberjar create a standalone executable jar file in the target directory
- copy the jar and the public directory to your production server
- ```sh java -jar target/lein-template-standalone.jar --profile prod --port 8000
I have absolutely no idea what the third step is or where I should put that command.