Set Up Rclone with Proton Drive on Pop!_OS

·

·

, ,
A hand touching a drive

Introduction

Managing your cloud storage effectively can streamline your workflow, especially when integrated with powerful tools like Rclone. This guide will walk you through the installation and configuration of Rclone to work seamlessly with Proton Drive on Pop!_OS 22.04 LTS (based on Ubuntu) since Proton Drive lacks a proper Linux client. The rclone implementation is based on the open-sourced client code and is currently in Beta.

Install/Upgrade Rclone

To get started, you’ll need to install or upgrade Rclone. Follow these commands in your terminal:

curl -O https://downloads.rclone.org/rclone-current-linux-amd64.zip  
unzip rclone-current-linux-amd64.zip  
cd rclone-*-linux-amd64  
sudo cp rclone /usr/bin/  
sudo chown root:root /usr/bin/rclone  
sudo chmod 755 /usr/bin/rclone  
# Cleanup  
rm rclone-*-linux-amd64.zip  
rm -r rclone-*-linux-amd64  

Configure Rclone for Proton Drive

Next, configure Rclone to connect with your Proton Drive account. Use the command below and follow the prompts:

rclone config  
  • Select protondrive.
  • Enter your drive name, for example, protondrive_business.
  • Provide your username, password, and 2FA code.
⚠️ WARNING
Ensure to finish and test the configuration before the 2FA code expires; otherwise, the connection won’t work.

Test your configuration with the following command:

rclone about protondrive_business:

Mount Remote Folder on Boot with Systemctl Service

To ensure your Proton Drive mounts automatically on boot, follow these steps:

  1. Prepare a target folder:

    mkdir /home/$USER/DRIVE_NAME
  2. Create a systemd service file:

    sudo nano /etc/systemd/system/rclone-mount.service
  3. Add the following content, replacing USER with your actual username:

    [Unit]
    Description=RClone Mount Service
    After=network-online.target
    Wants=network-online.target
    
    [Service]
    Type=simple
    ExecStart=/usr/bin/rclone mount \
     protondrive_business: /home/USER/DRIVE_NAME \
     --log-level INFO --log-file "/tmp/rclone_pdrive.log" \
     --vfs-cache-mode full
    ExecStop=/bin/fusermount -u /home/
    Restart=on-failure
    RestartSec=30
    User=USER
    
    [Install]
    WantedBy=multi-user.target
  4. Save and exit the editor.

  5. Reload the system daemon:

    sudo systemctl daemon-reload
  6. Enable the service to start on boot:

    sudo systemctl enable rclone-mount.service
  7. Start the service:

    sudo systemctl start rclone-mount.service
  8. Check the service status:

    sudo systemctl status rclone-mount.service

    Ensure the status is active (running).

Optional: Monitor Rclone

To monitor the Rclone service and check logs, use the following command:

tail -f /tmp/rclone_pdrive.log

Conclusion

While the integration works, it remains to be seen how stable it works in a daily routine. However, so far the Rclone mount is running stable and is a great way to circumvent the fact Proton Drive lacks a proper Linux client.

Reaching Out

If you have any questions or need further assistance, feel free to reach out through our contact form.

References

More from the blog

Recommended Topics

Popular Tags

automation cloud-storage pop-os proton-drive rclone ubuntu