Skip to content

Instantly share code, notes, and snippets.

@mgaare
Created September 20, 2016 17:25
Show Gist options
  • Save mgaare/503d02061cd247055763249bda3d4471 to your computer and use it in GitHub Desktop.
Save mgaare/503d02061cd247055763249bda3d4471 to your computer and use it in GitHub Desktop.
(ns immutantbasic.core
(:require [immutant.web :as web]
[clojure.tools.nrepl.server :as repl]
[compojure.core :refer (defroutes)]
[compojure.route :as route]
[ring.middleware.resource :refer (wrap-resource)]
[ring.middleware.file :refer (wrap-file)])
(:gen-class))
(defroutes routes
(route/not-found "Not found."))
(defn app
[]
(-> routes
(wrap-resource "public")))
(defn -main
[& args]
(repl/start-server :port 9999)
(web/run (app) {:port 8888 :host "0.0.0.0"}))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment