Skip to content

Commit

Permalink
(metabase) cronify extract_tables
Browse files Browse the repository at this point in the history
  • Loading branch information
vincentporte committed Dec 5, 2023
1 parent 677d989 commit 9a27298
Show file tree
Hide file tree
Showing 2 changed files with 18 additions and 0 deletions.
1 change: 1 addition & 0 deletions clevercloud/cron.json
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
[
"0 3 * * 0 $ROOT/clevercloud/extract_tables.sh",
"0 4 * * 0 $ROOT/clevercloud/rebuild_index.sh",
"5 4 * * * $ROOT/clevercloud/update_index_daily.sh",
"0 5 * * * $ROOT/clevercloud/collect_daily_matomo_stats.sh",
Expand Down
17 changes: 17 additions & 0 deletions clevercloud/extract_tables.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
#!/bin/bash -l

# Rebuild index for the search engine.
#
# About clever cloud cronjobs:
# https://www.clever-cloud.com/doc/tools/crons/
#

if [[ "$INSTANCE_NUMBER" != "0" ]]; then
echo "Instance number is ${INSTANCE_NUMBER}. Stop here."
exit 0
fi

# $APP_HOME is set by default by clever cloud.
cd $APP_HOME

python manage.py extract_tables

0 comments on commit 9a27298

Please sign in to comment.