Swarmpit is almost entirely written in Clojure, this allows seamless transition between frontend and backend development.
Backend part of application runs in JVM and frontend utilizes custom React & MaterialUI components with RUM. Persistent data are stored in CouchDB. Docker is connected via a socket.
Leiningen manages project definition and its dependencies. Figwheel is used for frontend hot-reloading.
Prerequisites
- Leiningen 2.6.1 or newer
- Docker socket accessible on
/var/run/docker.sock
Start a REPL session
lein repl
and call function (run)
, which will start DB container and Swarmpit with Figwheel on http://localhost:3449
In order to use REPL on frontend side call additionally (browser-repl)
. Both (run)
& (browser-repl)
are
part of dev User
namespace.
Whole application can be build to jar
file
lein with-profile prod uberjar
and then packed into Docker image
docker build -t swarmpit .
In case of unexpected swarmpit behaviour, please create well-written issue here. It makes it easier to find & fix the problem accordingly. Please follow the template below, we really appreciate the effort.
Steps to reproduce:
1. create a service with any image
2. add an environment variable with name `MYVAR`
3. set `MYVAR` value to be `firstpart=second=third`
4. save the service
What happens:
- upon viewing the service, `MYVAR` with value `firstpart`
What should happen:
- upon viewing the service `MYVAR` should have value `firstpart=second=third`