Changeset View
Changeset View
Standalone View
Standalone View
dockerfiles/swh-web/entrypoint.sh
#!/bin/bash | #!/bin/bash | ||||
set -e | set -e | ||||
if [[ -d /src ]] ; then | if [[ -d /src ]] ; then | ||||
for srcrepo in /src/swh-* ; do | for srcrepo in /src/swh-* ; do | ||||
echo installing $srcrepo | echo installing $srcrepo | ||||
pip install -e . | pip install -e . | ||||
popd | popd | ||||
done | done | ||||
fi | fi | ||||
echo Installed Python packages: | |||||
pip list | |||||
if [ "$1" = 'shell' ] ; then | if [ "$1" = 'shell' ] ; then | ||||
exec bash -i | exec bash -i | ||||
else | else | ||||
echo "starting the swh-web server" | echo "starting the swh-web server" | ||||
# options: | # options: | ||||
# --verbosity to have sensible output | # --verbosity to have sensible output | ||||
# --insecure to serve the static css/js | # --insecure to serve the static css/js | ||||
# 0.0.0.0 so that we can actually reach the service. | # 0.0.0.0 so that we can actually reach the service. | ||||
exec python3 -m swh.web.manage runserver \ | exec python3 -m swh.web.manage runserver \ | ||||
--verbosity 3 \ | --verbosity 3 \ | ||||
--insecure \ | --insecure \ | ||||
0.0.0.0:5004 | 0.0.0.0:5004 | ||||
fi | fi |