Skip to content

Commit

Permalink
Merge #378 from remote-tracking branch 'origin/372-missingData'
Browse files Browse the repository at this point in the history
  • Loading branch information
dr0i committed Feb 20, 2024
2 parents b0c88f6 + fbc5549 commit 318c556
Showing 1 changed file with 12 additions and 2 deletions.
14 changes: 12 additions & 2 deletions cron.sh
Original file line number Diff line number Diff line change
Expand Up @@ -3,11 +3,20 @@
# explicitly without "-e" for it should not exit immediately when failed but write a mail
set -uo pipefail # See http://redsymbol.net/articles/unofficial-bash-strict-mode/
# Execute via crontab by hduser@weywot1:
# 00 1 * * * ssh sol@quaoar1 "cd /home/sol/git/lobid-gnd ; bash -x cron.sh >> logs/cron.sh.log 2>&1"
# 00 1 * * * [removed] git/lobid-gnd ; bash -x cron.sh >> logs/cron.sh.log 2>&1"
# 50 05 * * * [removed] git/lobid-gnd ; bash -x cron.sh 1day >> logs/cron.sh.log 2>&1"


IFS=$'\n\t'
RECIPIENT=lobid-admin
sbt -mem 4000 "runMain apps.ConvertUpdates $(tail -n1 GND-lastSuccessfulUpdate.txt)"
START_UPDATE=$(tail -n1 GND-lastSuccessfulUpdate.txt)
unset http_proxy

if [ -n "${1-}" ] && [ "$1" = "1day" ]; then
START_UPDATE=$(date --date='1 day ago' +%Y-%m-%dT%H:%M:%SZ)
fi

sbt -mem 4000 "runMain apps.ConvertUpdates ${START_UPDATE}"

if [ -s GND-updates.jsonl ]; then
sbt -Dindex.prod.name=gnd-test "runMain apps.Index updates"
Expand All @@ -19,3 +28,4 @@ if [ -s GND-updates.jsonl ]; then
bash ./checkCompactedProperties.sh gnd
fi
fi

0 comments on commit 318c556

Please sign in to comment.