minauthator/justfile

33 lines
912 B
Makefile

export RUST_BACKTRACE := "1"
export RUST_LOG := "trace"
export CONTEXT_ARGS := "--config config.toml --database tmp/dbs/minauthator.db --static-assets ./assets"
watch-server:
cargo-watch -x "run --bin minauthator-server -- $CONTEXT_ARGS"
server:
cargo run --bin minauthator-server -- $CONTEXT_ARGS
admin:
cargo run --bin minauthator-admin -- $CONTEXT_ARGS
docker-build:
docker build -t lefuturiste/minauthator .
docker-init-db:
docker run \
-v ./tmp/docker/config:/etc/minauthator \
-v minauthator-db:/var/lib/minauthator \
lefuturiste/minauthator \
/usr/local/bin/minauthator_init_db.sh
docker-run:
docker run \
-p 127.0.0.1:3085:8080 \
-v ./tmp/docker/config:/etc/minauthator \
-v minauthator-db:/var/lib/minauthator \
lefuturiste/minauthator
init-db:
sqlite3 -echo tmp/dbs/minauthator.db < migrations/all.sql