sourcecred/scripts/docker-entrypoint.sh
Vanessasaurus 08408a9706 Adding Docker container with instructions for running sourcecred (#1288)
Adding docker container recipe and instructions in README for running sourcecred

Signed-off-by: Vanessa Sochat <vsochat@stanford.edu>

Test plan: @decentralion verified that the commands work on a fresh setup prior to merging.
2019-08-23 13:23:35 +02:00

23 lines
426 B
Bash
Executable File

#!/bin/bash
case "$1" in
# Offer a shortcut for load + dev-server
"dev-preview")
shift
node /code/bin/sourcecred.js load "$@" || exit 1
exec yarn -s start --host 0.0.0.0
;;
# Expose several webpack operations
"dev-server")
exec yarn -s start --host 0.0.0.0
;;
"build")
shift
exec yarn -s build "$@"
;;
# Everything else, pass on to sourcecred.js
*)
exec node /code/bin/sourcecred.js "$@"
;;
esac