Odrive agent automatically run in the background on Ubuntu

I followed the instructions below for installation:

The question after that is how do you let odrive run in the background automatically? What is the preferred way?
Or did I miss something? :thinking:

I have now solved this in such a way that I have set up a user unit for systemd:

[Unit]
Description=Run odrive-agent in background
Wants=network-online.target
After=network.target network-online.target

[Service]
Type=forking
ExecStart=%h/.odrive-agent/bin/odriveagent
Restart=on-failure
RestartSec=5

[Install]
WantedBy=default.target

detailed in Github Gist: systemd user unit odrive.service

Hi @yves,
The method you are using is perfectly valid and the way that I auto-start the agent on my Linux box.

Are you finding that this is working as expected?

Hi @Tony

So far it works fine.

I am just surprised that there is no template for this in the installation description. A user who does not delve deeper into the operating system will not find a solution so easily.

Is it because Linux is only marginally supported or are you planning something for the future?

An installation script which installs odrive-agent and cli automatically and also creates a systemd unit and register the cli-binary would be great. I’m just thinking of going a step further and making a small SystenTray app in PyQt to make some feedback from odrive visible.

1 Like

Hi @yves,
Linux support as been fairly progressive, as we’ve continued to try to provide feature parity with the desktop versions. The Windows and Mac desktop client are what the vast majority of our users use, but we fully support the odrive agents.

Creating and maintaining packages is not a step we’ve taken yet, but it is something we’d like to offer in the future. odrive agent installation is currently very simple and straightforward (only two binaries that can be run from anywhere), so formal packaging hasn’t been seen as a high priority.

Providing a sample systemd configuration in the documentation is a good idea, and I’ll look at getting that in there.

That sounds great! Definitely let us know if you decide to move forward with that.

1 Like