Installation
Krab binary can be downloaded from GitHub. Other methods are listed below.
asdf
Krab provides asdf plugin:
asdf plugin add krab https://github.com/ohkrab/asdf-krab.git
# or
asdf plugin add krab git@github.com:ohkrab/asdf-krab.git
Install desired version:
asdf install krab 0.4.2
Set it to your project:
asdf local krab 0.4.2
docker
Docker images can be found at Docker hub 🐋
To start a docker container a DATABASE_URL
environment variable must be provided.
By default “krab” reads configuration from /etc/krab
that must be mounted as a volume,
the path can be changed by KRAB_DIR
environment variable.
Pull the docker image:
docker pull ohkrab/krab:nightly
Example:
docker run --rm \ # remove container after command execution
-e DATABASE_URL="..." \ # provide connection string
-v ${HOME}/project1:/etc/krab:ro \ # mount configuration volume
ohkrab/krab:nightly --version # run `--version` command from `qbart/krab:latest`
one-liner:
docker run --rm -e DATABASE_URL="..." -v ${HOME}/project1:/etc/krab:ro ohkrab/krab:nightly --version