Question

I have built my own website using clojure (noir), but I have no clue on how to deploy the website to a web hosting server. I know how to run it on a virtual port (localhost8080). Is there some sort of way to compile all clojure code into javascript and html so the third party web server will understand it and read it? or am is there another way for all of this? Thank you.

Was it helpful?

Solution

Just like many of the common Clojure web frameworks, noir is build on top of the ring framework. Ring produces Java servlets that are contained in .war files. Hosting providers know how to host war files. In general you use leiningen to produce a war file and give it to your hosting company through some manner of web interface (or by pushing it through git in the case of Heroku)

add the lein-ring plugin to your project.clj's plugin section

https://github.com/weavejester/lein-ring

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top