Simple Clojure web service project template.
Go to file
Gered 473bed92df remove wrap-base, just put the optional wrap-reload under http-server
i don't _really_ want to encourage the use of wrap-base as i think it
is usually the wrong place to add middleware to.

instead adding a placeholder :middleware list to the reitit ring-handler
as the intended alternative place for "global" middleware that needs to
be applied regardless of a reitit route match
2022-01-05 18:34:18 -05:00
resources/leiningen/new/simple_web_service remove wrap-base, just put the optional wrap-reload under http-server 2022-01-05 18:34:18 -05:00
src/leiningen/new fix up project profiles a bit and adjust some build settings 2021-12-22 18:30:50 -05:00
.gitignore initial commit 2021-12-21 18:42:05 -05:00
LICENSE initial commit 2021-12-21 18:42:05 -05:00
project.clj bump to next snapshot version for future development 2021-12-22 18:35:40 -05:00
README.md initial commit 2021-12-21 18:42:05 -05:00

Leiningen Template: Simple Clojure Web Service

A Leiningen template intended for creating new Clojure web service projects utilizing reitit.

This template primarily exists for my own personal use, so some stuff is definitely more oriented towards my own particular preferences regarding setup and organization of a Clojure project.

Usage

$ lein new net.gered/simple-web-service [your-project-name-here]

The resulting project starts up via a main function and during startup expects to be able to read an EDN configuration file located in the current working directory called config.edn.

The project can be run simply by:

$ lein run

A nREPL server will be started which can be connected to on port 7000 (configured via the aforementioned config.edn).

The web service's endpoints will be accessible over port 8080 (again, configured via the aforementioned config.edn). The Swagger UI page will be available at /api-docs/ e.g. http://localhost:8080/api-docs/

License

Copyright © 2021 Gered King

Distributed under the the MIT License. See LICENSE for more details.