[systemd-devel] [PATCH] Added support for EnvironmentDir
Kok, Auke-jan H
auke-jan.h.kok at intel.com
Wed Dec 19 10:52:58 PST 2012
On Wed, Dec 19, 2012 at 8:00 AM, Lennart Poettering
<lennart at poettering.net> wrote:
> On Mon, 10.12.12 17:27, Colin Guthrie (gmane at colin.guthr.ie) wrote:
>
>>
>> 'Twas brillig, and Pekka Lundstrom at 10/12/12 13:56 did gyre and gimble:
>> > + <term><varname>EnvironmentDir=</varname></term>
>> > + <listitem><para>Similar to
>> > + <varname>EnvironmentFile=</varname> but
>> > + reads the environment variables from a
>> > + directory containing files. Each file in
>> > + that directory named with ".conf" suffix
>> > + is read and prosessed and these files
>> > + should follow same syntax as files
>> > + listed with <varname>EnvironmentFile=</varname>.
>>
>>
>> While not commenting on the need/usefulness etc. of the patch, would it
>> be possible to make the EnvironmentFile directive simply support globbing?
>>
>> e.g. Rather than doing:
>>
>> EnvironmentDir=/etc/foo.d
>>
>> I could just have:
>>
>> EnvironmentFile=/etc/foo.d/*.conf
>>
>> That would, to me at least, seem slightly cleaner than adding a new
>> directive to parse (although this is just my opinion at first glance -
>> others may disagree!).
>
> I agree with Colin. This would be much nicer with globbing. Also, it
> would then be a natural extension to allow multiple files to be
> specified in a single line:
>
> EnvironmentFile=/etc/foo.conf /etc/foo.conf.d/*.conf /run/foo.conf.d/*.conf
>
> I'd be happy to merge such a patch.
Pekka, this will help a lot - thanks - looking forward to seeing this feature.
Auke
More information about the systemd-devel
mailing list