[systemd-devel] How to create a user instance service that requires a network connection?

Michael Biebl mbiebl at gmail.com
Wed Jun 3 09:57:24 PDT 2015


2015-06-03 18:39 GMT+02:00 Kay Sievers <kay at vrfy.org>:
> On Wed, Jun 3, 2015 at 6:32 PM, Will S <wsha.code+systemd at gmail.com> wrote:
>> My understanding is that the system and user instances of systemd are
>> completely isolated from each other. So I can not create a user unit file
>> with the option Requires=network-online.target. Is there any way for a user
>> instance service to get this functionality of waiting for the network to be
>> online before starting? From what I can tell, the systemd user instance is
>> relatively new. If it is not possible now, is there any planned feature that
>> would allow this functionality in the future that I should watch for?
>
> No. And there are no plans.
> Better make your application network aware and adjust to the
> environment during runtime.

For desktop/user applications, you could use something like glib's
GNetworkMonitor
https://developer.gnome.org/gio/stable/GNetworkMonitor.html

-- 
Why is it that all of the instruments seeking intelligent life in the
universe are pointed away from Earth?


More information about the systemd-devel mailing list