S3 storage for Images #16
Loading…
Reference in New Issue
No description provided.
Delete Branch "%!s(<nil>)"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
CLONE TO S3
rclone sync -P --transfers 10 --checkers 20 --retries 10 --low-level-retries 20 --s3-upload-concurrency 8 ./images/ haiky-s3:haiky/images/
or
rclone sync -P --transfers 10 ./images/ haiky-s3:haiky/images/
CLONE FROM S3
rclone sync -P haiky-s3:haiky/images/ ./restored-images/
CRON:
Cron-Eintrag für tägliche Synchronisierung um 2 Uhr
0 2 * * * /usr/bin/rclone sync -P --transfers 10 ./images/ haiky-s3:haiky/images/ > /var/log/rclone.log 2>&1
SCRIPT (sync_images.sh)
#!/bin/bash
BUCKET="haiky"
RCLONE_CONF="/path/to/rclone.conf"
LOG_FILE="/var/log/image-sync.log"
echo "$(date) Starting sync" >> $LOG_FILE
rclone sync -P
--log-file $LOG_FILE
--stats 1m
--exclude "*.tmp"
./images/ haiky-s3:$BUCKET/images/
echo "$(date) Sync completed" >> $LOG_FILE