diff --git a/clojure/content.md b/clojure/content.md index 6011e6e10..205309c71 100644 --- a/clojure/content.md +++ b/clojure/content.md @@ -8,9 +8,28 @@ Clojure is a dialect of the Lisp programming language. It is a general-purpose p # How to use this image -## Start a Lein/Clojure instance in your app +## Build tools -Since the most common way to use Clojure is in conjunction with [Leiningen (`lein`)](http://leiningen.org/), this image assumes that's how you'll be working. The most straightforward way to use this image is to add a `Dockerfile` to an existing Leiningen/Clojure project: +Clojure has three major approaches to building and running projects: + +1. [leiningen](https://leiningen.org) + 1. The oldest and probably most common tool +2. [boot](http://boot-clj.com) + 1. An alternative approach that solves similar problems as leiningen +3. [tools-deps](https://clojure.org/guides/deps_and_cli) + 1. A more recent official tool for some of the lein/boot use cases + +There are variants of this image for all three of these tools and their respective releases. The most basic form of these tags is: + +1. `clojure:lein` +2. `clojure:boot` +3. `clojure:tools-deps` + +But you can also append a hyphen and the version of that tool you'd like to use. For example, for lein 2.8.1 you can use this image: `clojure:lein-2.8.1`. + +## Run your app with leiningen + +Add a `Dockerfile` to an existing Leiningen/Clojure project with the following contents: ```dockerfile FROM %%IMAGE%% @@ -52,3 +71,7 @@ $ docker run -it --rm -v "$PWD":/usr/src/app -w /usr/src/app %%IMAGE%% lein uber ``` This will build your project into a jar file located in your project's `target/uberjar` directory. + +## More details + +See [the official image README](https://github.com/Quantisan/docker-clojure/blob/master/README.md) for more details about using this image with boot and tools-deps.