I would like my rclone cache to be remounted if my server reboots, I am a noob when it comes to ubuntu so I really have no idea how to do this or if its even actually possible.
Hoping a fine netizen could walk me through how to do this.
I would like my rclone cache to be remounted if my server reboots, I am a noob when it comes to ubuntu so I really have no idea how to do this or if its even actually possible.
Hoping a fine netizen could walk me through how to do this.
So you can use systemd to start up things on boot assuming you have root access.
You can put a file in /etc/systemd/system/rclone.service
the rclone bit can be whatever you want. My systemd looks like:
root@gemini:/etc/systemd/system cat gmedia-rclone.service
[Unit]
Description=RClone Service
After=network.target
Wants=network-online.target
[Service]
Type=notify
Environment=RCLONE_CONFIG=/data/rclone/rclone.conf
ExecStart=/usr/bin/rclone mount gcrypt: /GD \
--allow-other \
--bind 192.168.1.30 \
--buffer-size 1G \
--dir-cache-time 72h \
--drive-chunk-size 32M \
--fast-list \
--log-level INFO \
--log-file /home/felix/logs/rclone.log \
--umask 002 \
--vfs-read-chunk-size 128M \
--vfs-read-chunk-size-limit off
ExecStop=/bin/fusermount -uz /GD
Restart=on-failure
User=felix
Group=felix
[Install]
WantedBy=multi-user.target
and then you can:
systemctl enable rclone.service
systemctl start rclone.service
In theory, it should start on boot now
Thanks for the reply Animosity! I will give this a try in a day or two, are you on discord per chance incase I have issues?