https://github.com/null-none/lein-clojure
Quick run through of clojure, ring, and docker
https://github.com/null-none/lein-clojure
clojure docker docker-compose lein leiningen
Last synced: 2 months ago
JSON representation
Quick run through of clojure, ring, and docker
- Host: GitHub
- URL: https://github.com/null-none/lein-clojure
- Owner: null-none
- License: mit
- Created: 2023-03-15T10:17:12.000Z (almost 3 years ago)
- Default Branch: main
- Last Pushed: 2023-03-15T10:22:01.000Z (almost 3 years ago)
- Last Synced: 2025-10-17T01:49:41.815Z (3 months ago)
- Topics: clojure, docker, docker-compose, lein, leiningen
- Language: Clojure
- Homepage:
- Size: 1.95 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# lein-clojure
Stting up a quick docker + clojure service example.
## Usage
### Clear
```bash
docker system prune -a
docker volume prune
docker stop $(docker ps -a -q)
docker rm $(docker ps -a -q)
docker rmi $(docker images -a -q)
```
### Start
```bash
docker-compose build web --no-cache
docker-compose run web
```
#### Example
GET to the `/` endpoint
```bash
curl http://localhost:3000
```
POST to the `/sum` endpoint
```bash
curl -X POST http://localhost:3000/sum \
-d '{"numbers": [1,2,7]}' \
--header "Content-type:application/json"
```