Pass-through api that mimics and caches configured endpoint responses.
This project uses tools.deps, to run an nrepl on port 9000 call:
clojure -A:nrepl
Included is a dev alias that allows you to run a development jetty server that reloads the aplicaition on file changes. The command is:
clojure -A:dev
This can work in conjunction with the nrepl by calling:
clojure -A:dev:nrepl
When the nrepl is started it will run the usr.clj in the dev directory and expose (start)
and (stop)
wich will start and stop the dev server manually.
I suggest rather than installing docker locally you should install docker and pull the postgres container.
- Install Docker for your system using Docker CE.
- Pull postgres container using
docker pull postgres
. - create a folder that will contain the volume for docker
mkdir -p $HOME/docker/volumes/postgres
. - Run the docker container
sudo docker run --rm --name pg-docker -e POSTGRES_PASSWORD=<password> -d -p 5432:5432 -v $HOME/docker/volumes/postgres:/var/lib/postgresql/data postgres
. - Note here the docker password can be whatever you like, and must match the one added to the following commands.
Migrations are run with the library yogthos/migratus. To run the data migrations on your machine you can use the command DATABASE_PW=<docker> clj -A:migrations -m migrations
or the simpler DATABASE_PW=<docker> make migrate
. To rollback, add rollback
to either commands.