jualhosting commited on
Commit
274c0f4
·
verified ·
1 Parent(s): 8e9aa0c

Upload 4 files

Browse files
Files changed (1) hide show
  1. entrypoint.sh +3 -3
entrypoint.sh CHANGED
@@ -44,11 +44,11 @@ touch "$DB_PATH"
44
 
45
  # 1. Download database from Google Drive if it exists
46
  echo "Checking for persistent database on Google Drive..."
47
- rclone copyto "$REMOTE_NAME:.filebrowser.db" "$DB_PATH" --config "$CONFIG_PATH" || true
48
 
49
  # 2. Download files from Google Drive to local /data directory
50
  echo "Syncing files from Google Drive..."
51
- rclone copy "$REMOTE_NAME:" "$DATA_DIR" --config "$CONFIG_PATH" || true
52
 
53
  # 3. Start background sync loops
54
  # Loop A: Sync files in /data to Google Drive when modified
@@ -59,7 +59,7 @@ rclone copy "$REMOTE_NAME:" "$DATA_DIR" --config "$CONFIG_PATH" || true
59
  inotifywait -r -e modify,create,delete,move "$DATA_DIR"
60
  sleep 5
61
  echo "Changes detected in $DATA_DIR, copying to Google Drive ($REMOTE_NAME)..."
62
- rclone copy "$DATA_DIR" "$REMOTE_NAME:" --config "$CONFIG_PATH"
63
  done
64
  ) &
65
 
 
44
 
45
  # 1. Download database from Google Drive if it exists
46
  echo "Checking for persistent database on Google Drive..."
47
+ rclone copyto "$REMOTE_NAME:.filebrowser.db" "$DB_PATH" --config "$CONFIG_PATH" --drive-skip-shortcuts --drive-acknowledge-abuse || true
48
 
49
  # 2. Download files from Google Drive to local /data directory
50
  echo "Syncing files from Google Drive..."
51
+ rclone copy "$REMOTE_NAME:" "$DATA_DIR" --config "$CONFIG_PATH" --drive-skip-shortcuts --drive-acknowledge-abuse || true
52
 
53
  # 3. Start background sync loops
54
  # Loop A: Sync files in /data to Google Drive when modified
 
59
  inotifywait -r -e modify,create,delete,move "$DATA_DIR"
60
  sleep 5
61
  echo "Changes detected in $DATA_DIR, copying to Google Drive ($REMOTE_NAME)..."
62
+ rclone copy "$DATA_DIR" "$REMOTE_NAME:" --config "$CONFIG_PATH" --drive-skip-shortcuts --drive-acknowledge-abuse
63
  done
64
  ) &
65