aboutsummaryrefslogtreecommitdiff
path: root/src/cashflow/core.clj
blob: 530af728caee026d0b54a9c060b3e98514258719 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
(ns cashflow.core
  (:require [cashflow.routes :as croutes]
            [dotenv :as env]
            [org.httpkit.server :as http-server])
  (:import java.lang.Integer)
  (:gen-class))

(defn -main [& args]
  (let [port (-> (env/env "WEB_PORT")
                 (or "8080")
                 Integer/parseInt)])
  (println "Starting web server at port 8080...")
  (http-server/run-server croutes/ring-handler {:port 8080}))