messenger / sync_loop.sh
lvwerra's picture
lvwerra HF Staff
Upload folder using huggingface_hub
7559040 verified
raw
history blame contribute delete
380 Bytes
#!/bin/bash
# Periodic sync of Conduit database to HF bucket
while true; do
sleep 60
if [ -n "$HF_TOKEN" ] && [ -d /data/conduit ]; then
hf buckets sync /data/conduit/ hf://buckets/lvwerra/messenger-storage/conduit-db/ \
2>&1 || echo "Sync failed, will retry"
else
echo "Sync skipped: HF_TOKEN not set or /data/conduit missing"
fi
done