Bug#766757: Generated services should start After=systemd-user-sessions.service

Yuri D'Elia wavexx at thregr.org
Sat Oct 25 17:03:30 BST 2014


On 10/25/2014 05:01 PM, Alexandre Detiste wrote:
> Hi,
> 
>> The generated service template should include:
>>
>> After=systemd-user-sessions.service
>  
> Should this be for everyone, or only user != 'root' ?

I would say also for root.

>> to actually ensure the user directory is available/ready before starting the job.
> 
> Isn't  "DefaultDependencies=true" enough ?

If I understand the manual page of systemd.service, DefaultDependencies
sets just After=basic.target and Before=shutdown.target, which may still
starts the service too early for an user process (see basic.target itself).

Ideally we should depend on the user's home directory as a valid mount
point as well, but I'm not sure in how to do that properly.




More information about the Pkg-systemd-maintainers mailing list