
# Immich
![[immich_unraid_setup4.png]]

![[immich_unraid_setup3.png]]

![[immich_unraid_setup2.png]]

![[immich_unraid_setup1.png]]

# rclone
1. Install rclone plugin, not docker, in unraid
2. use `rclone config` and follow the [backblakze rclone setup page](https://www.backblaze.com/docs/cloud-storage-integrate-rclone-with-backblaze-b2#create-a-bucket) to set up the remote
    1. Create ONE name for the remote which contains all the buckets. In this case, we use 'b2'
    2. 
2. Use `rclone config` again and follow [rclone crypt page](https://rclone.org/crypt/) to set up encryption
    1. The password and salt are stored 1pass's backblaze item
    2. Name can be `b2-crype:{bucket_name}`
3. Commands
    1. copy files - `rclone copy /mnt/user/la-share/syncthing/main/martial_arts b2-crypt:ylu-test -P --bwlimit 10M:10M --fast-list --check-first --order-by=name --log-file=/mnt/user/la-share/rclone/rclone.log --log-file-max-size 1M --log-file-max-backups 3 --log-level=INFO --combined=/mnt/user/la-share/rclone/report.log`
        1. Modified files will create new file version in backblaze
    2. list files - `rclone ls b2-crypt:ylu-test`
    3. sync files - `rclone sync /mnt/user/la-share/syncthing/main/martial_arts b2-crypt:ylu-test -P --bwlimit 10M:10M --fast-list --check-first --order-by=name --log-file=/mnt/user/la-share/rclone/rclone.log --log-file-max-size 1M --log-file-max-backups 3 --log-level=INFO --combined=/mnt/user/la-share/rclone/report.log`
        1. deleted files will stay hidden in backblaze and the hidden one doesn't take any space
    4. delete files - `rclone backend cleanup-hidden b2:ylu-test -P --fast-list --log-file=/mnt/user/la-share/rclone/rclone.log --log-file-max-size 1M --log-file-max-backups 3 --log-level=INFO`
        1. Use it on the underlying remote, not the crypt remote
        2. This will actually remove the hidden files