Cloud Sync Task - add extra rclone args to AWS S3

shilazi

Cadet
Joined
Feb 22, 2022
Messages
2
Hello guys, I am a user from China. Compared to AWS S3, i use Alibaba Cloud which is faster, they are OSS of S3 protocol. But I can't use Cloud Sync Task directly because it doesn't support configuring force_path_style.

A solution has been found on rclone GitHub issues, only need to configure force_path_style = false Can be adapted to Alibaba Cloud.
https://github.com/rclone/rclone/issues/2401#issuecomment-405979278
https://github.com/rclone/rclone/issues/1641#issuecomment-453765963

I've been through the rclone posts and I can't find a way to configure it, so i modified the source code and restarted TrueNAS Scale, but that's too low. Whether Auxiliary Parameters can be added to the Cloud Sync Task configuration page in the next release like Rsync Task ?

The version I'm using is TrueNAS-SCALE-22.02.0, and the modified code block is as follows:
for k, v in config.items():
self.tmp_file.write(f"{k} = {v}\n")

+ if self.provider.rclone_type == "s3":
+ self.tmp_file.write("force_path_style = False\n")
+
self.tmp_file.flush()

 

shilazi

Cadet
Joined
Feb 22, 2022
Messages
2
Hello guys, I am a user from China. Compared to AWS S3, i use Alibaba Cloud which is faster, they are OSS of S3 protocol. But I can't use Cloud Sync Task directly because it doesn't support configuring force_path_style.

A solution has been found on rclone GitHub issues, only need to configure force_path_style = false Can be adapted to Alibaba Cloud.
https://github.com/rclone/rclone/issues/2401#issuecomment-405979278
https://github.com/rclone/rclone/issues/1641#issuecomment-453765963

I've been through the rclone posts and I can't find a way to configure it, so i modified the source code and restarted TrueNAS Scale, but that's too low. Whether Auxiliary Parameters can be added to the Cloud Sync Task configuration page in the next release like Rsync Task ?

The version I'm using is TrueNAS-SCALE-22.02.0, and the modified code block is as follows:
Forgot to paste the modified file path is /usr/lib/python3/dist-packages/middlewared/plugins/cloud_sync.py

ps: My English is not very good, I use machine translation. Best wishes! (●'◡'●)
 

SKiZZ

Dabbler
Joined
Feb 17, 2022
Messages
26
Forgot to paste the modified file path is /usr/lib/python3/dist-packages/middlewared/plugins/cloud_sync.py

ps: My English is not very good, I use machine translation. Best wishes! (●'◡'●)
You ever figure this out as I'd like to add additional parameters for google cloud.
 
Top