On Mon, Oct 5, 2009 at 8:10 AM, Allan Marcus <[email protected]> wrote:
>
> Very nice. I think there should be support for "delete". Maybe expand
> "ensure" parameter with values:
>
> present: create key/value if not there, do nothing if there
> absent: remove the key - the value param would not be needed
> force: create key/value if not there, force the value to equal the
> value param
>
> I'm not sure why the parameter "auth_membership" is called that. Would
> this option let me set or replace one value or an array or dict and
> not blow away the other values, if it were set to true? If set to
> false, it would blow away all other array/dict values?
>
> Also, will it handle the plists in byhost correctly? Figuring our
> which plist file to change is half the battle. I know there were some
> articles in recent MacTech magazines about this topic. Have you read
> them?
>
> This look like it's the beginning of being able to manage MCX items
> via puppet in a more efficient manner. Awesome. Once it's ready, I can
> envision a ton of type definition libraries to manage all the common
> stuff.
So you know we have an MCX type already? The problem with it is that
it's the *whole* MCX setting for that object record.
root# ralsh mcx /Computers/localhost
mcx { '/Computers/localhost':
ensure => 'present',
content => '<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN"
"http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>com.apple.MCX</key>
<dict>
<key>cachedaccounts.create.encrypt</key>
<dict>
<key>state</key>
<string>always</string>
<key>value</key>
<string>0</string>
</dict>
</dict>
</dict>
</plist>
'
}
The primary reason Jeff and I went down that path was due to the
horror that is things like managing the Dock with MCX, where you have
many nested values that would be impossible to neatly specify in the
puppet DSL.
I do want to subclass this provider and do an 'mcxkey' provider that
would look something like this for the case above:
mcx { '/Computers/localhost':
ensure => 'present',
appdomain => 'com.apple.MCX',
keyname => 'cachedaccounts.create.encrypt',
mcxdomain => 'always',
keyvalue => '0',
}
It also looks like you can now use Union Policy Keys to specify more
complicated MCX controls, so allowing that would also be useful.
-------------------
mcxset . com.apple.test testkey-Raw always '(1,2,3)' '{
input=testkey-Raw; output=testkey; mcx_remove_duplicates=1;
mcx_replace=1; mcx_union_as_dictionary=0;}'
mcxset . com.apple.test testkey-Raw always '{ keya=a; keyb=b;
keyc=c; }' '{ output=testkey; mcx_union_as_dictionary=1;}'
------------------
I think we should continue to support the MCX type and do a plist type
completely separately.
>
> ---
> Thanks,
>
> Allan Marcus
> 505-667-5666
>
>
>
> On Oct 5, 2009, at 8:52 AM, Carl Caum wrote:
>
>> Nigel Kersten and I had previously worked on a plist provider spec
>> for Mac OS X. Attached is a PDF of the current state. I would
>> appreciate any input and criticisms.
>>
>> >
>> <Puppet Plist native type spec.pdf>
>
>
> >
>
--
nigel
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"Puppet Users" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/puppet-users?hl=en
-~----------~----~----~----~------~----~------~--~---