Skip to content

Commit 6f485b0

Browse files
authored
Celery beat: remove .db at startup to avoid corrupted db (#173)
* Celery beat: remove .db at startup to avoid corrupted db * Update dockerfiles/entrypoints/celery-beat.sh
1 parent d1ad897 commit 6f485b0

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

dockerfiles/entrypoints/celery-beat.sh

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,11 @@
44

55
CMD="python3 -m celery -A ${CELERY_APP_NAME}.worker beat -l ${CELERY_LOG_LEVEL}"
66

7+
# Not sure why, but the db becomes corrupted at some point
8+
# and make the startup of this process to fail.
9+
# Removing it makes Celery to re-create it.
10+
rm -f celerybeat-schedule.db
11+
712
if [ -n "${DOCKER_NO_RELOAD}" ]; then
813
echo "Running process with no reload"
914
$CMD

0 commit comments

Comments
 (0)