This service will use the same remote name you specified when using rclone config create. If you haven't done that yet, do so now.
Next, create the mountpoint for your remote. The service uses the location ~/mnt/<remote> by default.
mkdir ~/mnt/dropboxThe --allow-other option is required in order to work in many desktop environments. This flag must be enabled by adding user_allow_other to /etc/fuse.conf. If you aren't using a desktop environment, such as on a server, this option can be omitted.
Save the [email protected] file in ~/.config/systemd/user/
Make sure you include the @. This is required to work.
As your normal user, run:
systemctl --user daemon-reloadYou can now start/enable each remote by using rclone@<remote>
systemctl --user enable --now rclone@dropbox
This is not necessarily an issue with this exact systemd unit, but I just want to leave this hint here for anybody that makes the same stupid mistake as me: If you use rclone and this systemd unit to mount an SMB network share and your share is unavailable (or misconfigured), this may cause a huge delay whenever you're opening your file manager (or when any software opens a "Save as" prompt).
Was using the following settings
And mounted it with this systemd unit.
Then I forgot about it, turned my NAS off two months later, and was dumbfounded for a week why my file manager takes 30-60 seconds to open everytime. 🤦