[lispyclouds/clj-docker-client "0.1.4"]
An idiomatic Clojure Docker client based on the excellent JVM client by Spotify.
This is a work in progress and aims to be fully compliant and up to date with the Docker API changes.
(require '[clj-docker-client.core :as docker])
(def conn (docker/connect))
(docker/ping conn)
busybox:musl
image(docker/pull conn "busybox:musl")
(docker/build conn "full path to directory containing a Dockerfile")
(docker/push conn "image id or <repo>:<tag>")
(docker/image-rm conn "image id or <repo>:<tag>")
(docker/image-ls conn)
busybox:musl
image, a command and a env var(docker/create conn "busybox:musl" "echo hello" {:env "testing"})
(docker/ps conn) ; Only running containers
(docker/ps conn true) ; All containers
(docker/start conn "name or id")
(docker/stop conn "name or id")
(docker/kill conn "name or id")
(docker/rm conn "id or name") ; Remove non-running container
(docker/rm conn "id or name" true) ; Force remove non-running container
Can you improve this documentation?Edit on GitHub
cljdoc is a website building & hosting documentation for Clojure/Script libraries
× close