[PATCH] string options in *.policy.mount_option

Juergen Orschiedt jorschiedt at web.de
Thu Sep 1 14:33:11 PDT 2005


On Thu, 2005-09-01 at 16:54 -0400, David Zeuthen wrote:
> Hi,
> 
> Sorry for the lag,
> 
> On Wed, 2005-08-31 at 00:07 +0200, Juergen Orschiedt wrote:
> > A month ago, rider at altlinux.com sent a patch against libhal-storage.c
> > which would allow the usage of string options in mount_options.
> > I added a missing "else", because it generated empty fields when a
> > boolen value was reset by the policy.
> > 
> > So now you can create mount_options like
> > 
> > <deviceinfo version="0.2">
> >     <device>
> >         <match key="volume.policy.should_mount" bool="true">
> >             <merge key="volume.policy.mount_option.pamconsole"
> > type="bool">false</merge>
> >             <merge key="volume.policy.mount_option.gid"
> > type="string">users</merge>
> >             <merge key="volume.policy.mount_option.noauto"
> > type="bool">false</merge>
> >             <merge key="volume.policy.mount_option.umask"
> > type="string">0002</merge>
> >         </match>
> >    </device>
> > </deviceinfo>
> > 
> > Attached you'll find the patch against hal-0.5.4cvs
> 
> So, two things
> 
>  1. You can do this already, for example
> 
>     <merge key="volume.policy.mount_option.umask=0002" type="bool">true</merge>
> 
>     should do the trick.
> 
>     See the spec for details: http://cvs.freedesktop.org/*checkout*/hal/hal/doc/spec/hal-spec.html#device-properties-storage-policy-default
> 
Got it... the "bool" confused me a bit...




More information about the hal mailing list