finalize connection check manage.py command

This commit is contained in:
simon
2023-02-01 16:05:29 +07:00
parent 2f685859cf
commit 1b5a810520
2 changed files with 97 additions and 27 deletions

View File

@@ -1,25 +1,12 @@
#!/bin/bash
# startup script inside the container for tubearchivist
set -e
# check environment
python manage.py ta_envcheck
python manage.py ta_connection
# wait for elasticsearch
# counter=0
# until curl -u "$ELASTIC_USER":"$ELASTIC_PASSWORD" "$ES_URL" -fs; do
# echo "waiting for elastic search to start"
# counter=$((counter+1))
# if [[ $counter -eq 12 ]]; then
# # fail after 2 min
# echo "failed to connect to elastic search, exiting..."
# curl -v -u "$ELASTIC_USER":"$ELASTIC_PASSWORD" "$ES_URL"?pretty
# exit 1
# fi
# sleep 10
# done
# start python application
python manage.py makemigrations
python manage.py migrate