chef
https://github.com/opscode/chef
Ruby
A systems integration framework, built to bring the benefits of configuration management to your entire infrastructure.
Chef::Mixin::Securable::WindowsMacros#rights_attribute
=== rights_attribute "meta-method" for dynamically creating rights attributes on resources. Multiple rights attributes can be declared. This enables resources to have multiple rights attributes with separate runtime states. For example, +Chef::Resource::RemoteDirectory+ supports different rights on the directories and files by declaring separate rights attributes for each (rights and files_rights). ==== User Level API Given a resource that calls rights_attribute(:rights) Then the resource DSL could be used like this: rights :read, ["Administrators","Everyone"] rights :deny, "Pinky" rights :full_control, "Users", :applies_to_children => true rights :write, "John Keiser", :applies_to_children => :containers_only, :applies_to_self => false, :one_level_deep => true ==== Internal Data Structure rights attributes support multiple right declarations in a single resource block--the data will be merged into a single internal hash. The internal representation is a hash with the following keys: * `:permissions`: Integer of Windows permissions flags, 1..2^32 or one of `[:full_control, :modify, :read_execute, :read, :write]` * `:principals`: String or Array of Strings represnting usernames on the system. * `:applies_to_children` (optional): Boolean * `:applies_to_self` (optional): Boolean * `:one_level_deep` (optional): Boolean
Edit
git clone [email protected]:opscode/chef.git
cd chef
open lib/chef/mixin/securable.rb
Contribute
# Make a new branchgit checkout -b -your-name--update-docs-Chef--Mixin--Securable--WindowsMacros-rights_attribute-for-pr
# Commit to gitgit add lib/chef/mixin/securable.rbgit commit -m "better docs for Chef::Mixin::Securable::WindowsMacros#rights_attribute"
# Open pull requestgem install hub # on a mac you can `brew install hub`
hub fork
git push <your name> -your-name--update-docs-Chef--Mixin--Securable--WindowsMacros-rights_attribute-for-pr
hub pull-request
# Celebrate!