some tests, and docker fix
[cas.git] / manage
1 #!/bin/sh
2
3 if [ "$1" = "runserver" ]
4 then
5     PORT="$2"
6     [ -z "$PORT" ] && PORT=8000
7     EXPOSED=127.0.0.1:"$PORT"
8     echo "expose as: $EXPOSED"
9     exec docker-compose run -p "$EXPOSED":"$PORT" dev python $PYARGS manage.py runserver 0.0.0.0:"$PORT"
10 else
11     exec docker-compose run dev python $PYARGS manage.py "$@"
12 fi