How to convert my program into a service?

Bo Berglund bo.berglund at gmail.com
Tue Mar 30 18:55:39 UTC 2021


On Tue, 30 Mar 2021 18:49:06 +0200, Ralf Mardorf via ubuntu-users
<ubuntu-users at lists.ubuntu.com> wrote:

>>Inserting the command line in a small script that loads in the
>>.profile of the user wouldn't do the trick?
>
>This assumes that a session for this user/group gets started. I suspect
>the OP doesn't want to do this. FWIW systemd has got also mechanisms to
>launch user session specific units.

The system is unattended and has no user interface. It just runs the service
through which it can be controlled. So it really does not matter if it is
running as root, since the retrieval of the data is via the TCP/IP socket
interface where the client asks the server for a chunk of data (being packaged
in a zip file).

I was just curious for other reasons and while looking online for other stuff I
have seen an example unit file where a user is specified.
But I will see later if it is needed or not.


-- 
Bo Berglund
Developer in Sweden





More information about the ubuntu-users mailing list