Class: Chef::Resource::ChefUser

Inherits:
LWRPBase
  • Object
show all
Defined in:
lib/chef/resource/chef_user.rb

Instance Method Summary collapse

Constructor Details

#initialize(*args) ⇒ ChefUser

Grab environment from with_environment



11
12
13
14
# File 'lib/chef/resource/chef_user.rb', line 11

def initialize(*args)
  super
  chef_server run_context.cheffish.current_chef_server
end

Instance Method Details

#after(&block) ⇒ Object

Proc that runs after the resource completes. Called with (resource, json, private_key, public_key)



48
49
50
# File 'lib/chef/resource/chef_user.rb', line 48

def after(&block)
  block ? @after = block : @after
end

#before(&block) ⇒ Object

Proc that runs just before the resource executes. Called with (resource)



43
44
45
# File 'lib/chef/resource/chef_user.rb', line 43

def before(&block)
  block ? @before = block : @before
end