[systemd-devel] Started process not attach to its related service.

Holger Kiehl Holger.Kiehl at dwd.de
Tue Nov 22 10:46:30 UTC 2016


On Tue, 22 Nov 2016, Mantas Mikulėnas wrote:

> So, uh, that sounded like you value updating one file less (and even mixing
> user and daemon configs) above having the service actually work?
>
But users do test things under their login environment and expect them
to run in this environment. So for some applications this is a must.

> Not that it's an excuse anyway. Systemd units have EnvironmentFile= for
> importing environment variables. Even init.d scripts can use `source` with
> the same effect, as can users' own .profile or .foorc scripts... There are
> plenty of nice ways to "share environment variables" without using su.
> 
Users have different shell's and even distributions name them differently
(.profile, .bash_profile). With EnvironmentFile= you force the user to put
the same things at two different places. With su you do not have to
think about all these problems.

Regards,
Holger

> That said, at least try `runuser`...
> 
> On Tue, Nov 22, 2016, 12:07 Benoit SCHMID <Benoit.Schmid at unige.ch> wrote:
>       Hello,
> 
>       On 11/22/2016 10:58 AM, Jonathan de Boyne Pollard wrote:
>       > Don't abuse su for dropping privileges.
> 
>       I agree that using su has drawbacks.
> 
>       But it also have advantages.
>       When you upgrade your db, you upgrade the environment variables.
>       Therefore using su allow you to centralised everything in one
>       place
>       (user settings).
> 
>       This is why, after thinking of the pros and cons, I use su,
>       even if I agree with you, on the fact that should not abuse :-)
> 
>       Regards,
> 
>       --
>       _/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/
> 
>            Benoit Schmid              Tel: (+41-22) 379-7209
> 
>            University of Geneva - Information Technology Division
> 
>       _/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/
> 
>       _______________________________________________
>       systemd-devel mailing list
>       systemd-devel at lists.freedesktop.org
>       https://lists.freedesktop.org/mailman/listinfo/systemd-devel
> 
> 
> 


More information about the systemd-devel mailing list