A better way to use pCloud with Synology Cloud Sync

Previous Solutions and why they are not very good:

  • Turn off 2FA for pCloud account and use WEBDAV:
    • This has inherent security concerns
    • Using this method appears to be unnofficially supported as pcloud.com no longer mentions the endpoints for this implementation in their F.A.Q.
  • Pull data to pCloud using something like multcloud.com
    • Great idea except for if the NAS is not publicly facing or is on a Double NAT network
    • In my experience it doesnt seem to work and freezes quite often.

My Current solution and its benefits:

I am now using the docker package in addition to the synology cloudsync package and simply run the official rclone/rclone:latest docker container with the serve webdav command and use that container to handle communication from cloud sync to my pcloud account.

  • Uses officially supported Synology Packages
  • Uses a stable version of webdav built into rclone
  • Supports the 2FA security since rclone uses that authentication method for pcloud
  • Supports easy configuration with cloud sync
  • Credentials are token based and stored on the synology diskstation
  • It is fast.
  • It can work with any rclone backend cloud provider not just pcloud

Guide to set my solution up:

  1. Install cloud sync and docker packages:
  2. Login to the Synology with admin access
  3. Open the Package Center App
  4. Search and Install the Cloud Sync and Docker Packages
  5. Download the rclone/rclone docker image:
  6. On the Registry pane in the Docker app search and add rclone/rclone:latest
  7. Create rclone config file:
  8. On your personal computer use a terminal or shell window to run rclone locally.
  9. If you don’t already have rclone installed on your machine with your web browser follow the instructions here first for your computer’s operating system: https://rclone.org/install/
  10. Follow the instructions on your computer to create a rclone config file for your desired backend cloud.
  11. you can find the general documentation for how to do that here: https://rclone.org/remote_setup/#configuring-by-copying-the-config-file
  12. Copy the config file with your desired backend to your Synology DiskStation.  I like to keep files like this in a dedicated folder share.
  13. launch the rclone/rclone docker image:
  14. Navigate to the Images pane in the Docker App in DSM
  15. Select the rclone/rclone:latest image and click launch
  16. Leave the network settings alone they do not matter
  17. Choose a name for your container(recommended)
  18. Configure the resource allocation to your liking and enable auto-restart(recommended)
  19. Click Advanced Settings
  20. On the Execution Command tab enter something like the following pattern replacing the bracketed values with your own choices but be sure you remember what you put for these values.
  21. serve webdav –addr :<rclone_webdav_port> –user <webdav_username> –pass <webdav_pass> –vfs-cache-mode full <rclone_backend_name>:<path_in_cloud_to_make_available>
  22. for example you could use the values like this for pcloud (Please use more secure authentication than this example, and don’t put your DiskStation as the DMZ of your network, use a firewall at the very least)
  23. <rclone_webdav_port>: 8585
  24. <webdav_username>: droidtastic
  25. <webdav_password>: thesearenotthedroidswearelookingfor
  26. <rclone_backend_name>: pcloud
  27. <path_in_cloud_to_make_available>: / or blank,  this is optional but the colon is required in the command above
  28. Save the command and click next and you can enter the Port mapping
  29. Enter the port you used in your command under the <rclone_webdav_port> on both sides for local port and container port and use TCP as the type of port
  30. Clicking next will allow you to setup the config folder to be available to the rclone docker container
  31. Click add folder and choose the folder that has the rclone config inside of it that you uploaded to your diskstation earlier in this guide.
  32. It has to be a folder and it needs to be writable (not read only) because rclone will automatically update the oauth token used by several cloud providers since they regularly expire.
  33. Then enter /config/rclone for the mount path
  34. Click next check to run the container and click done
  35. You can click the details of the container and see that the logs show the web dav server running.
  36. Hard part is done Hooray!
  37. Connect Cloud Sync to docker container:
  38. Open the cloud sync app
  39. Add a webdav connection
  40. Enter the details from your rclone webdav server:
  41. Using the previous example we would use the following:
  42. Server address: http://localhost:8585
  43. User account: droidtastic
  44. Password: thesearenotthedroidswearelookingfor
  45. Click next
  46. Choose a conneciton name, local path on your DiskStation, Remote path on your cloud account and the Sync direction.
  47. Clicking next will start syncing that folder with your cloud, in my case pcloud for now.
  48. Enjoy 🙂

     

    I hope you find this guide useful, I cannot believe no one else even mentions this as a possible and viable solution for Synology Cloud Sync.

    Like anything you read online:

    Use this with caution, nothing I post here makes any claims that what works for me will work for you and when dealing with data, backups and security it is always best to conduct your own testing in a safe(duplicated, non production data) manner.

     

    Thanks for reading,

    – Blaine