Skip to content

Instantly share code, notes, and snippets.

@yzl
Last active August 29, 2015 13:57
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save yzl/9699474 to your computer and use it in GitHub Desktop.
Save yzl/9699474 to your computer and use it in GitHub Desktop.
Overriding one of chef's providers in an HWP
libraries/platform_provider_mapping.rb:
require 'chef/platform'
require_relative 'osx_group'
Chef::Platform.set(
platform: :mac_os_x,
resource: :group,
provider: Chef::Provider::Group::Osx,
)
libraries/osx_group.rb:
class Chef
class Provider::Group::Osx < Provider::Group
...
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment