Adoptable Cookbooks List

Looking for a cookbook to adopt? You can now see a list of cookbooks available for adoption!
List of Adoptable Cookbooks

Supermarket Belongs to the Community

Supermarket belongs to the community. While Chef has the responsibility to keep it running and be stewards of its functionality, what it does and how it works is driven by the community. The chef/supermarket repository will continue to be where development of the Supermarket application takes place. Come be part of shaping the direction of Supermarket by opening issues and pull requests or by joining us on the Chef Mailing List.

Select Badges

Select Supported Platforms

Select Status

RSS

delayed_evaluator (2) Versions 0.1.0

Delay stuff!

Policyfile
Berkshelf
Knife
cookbook 'delayed_evaluator', '= 0.1.0', :supermarket
cookbook 'delayed_evaluator', '= 0.1.0'
knife supermarket install delayed_evaluator
knife supermarket download delayed_evaluator
README
Dependencies
Quality -%

DelayedEvaluator

This is a PoC cookbook to show a working solution for delayed
attribute evaluation within resource blocks. The relevant
Chef ticket is here:

Example

Below is an example recipe to demonstrate the usage.

include_recipe 'delayed_evaluator'

node.default[:testbook][:test_content] = "I'm the compile time value!"

ruby_block 'reset test content' do
  block do
    node.default[:testbook][:test_content] = "I'm the execution time value!"
  end
end

file '/opt/test_no_delay' do
  content node[:testbook][:test_content]
end

file '/opt/test_delay' do
  content delay_eval{ node[:testbook][:test_content] }
end

Note that the evaluation block must be provided to the delay_eval
method. It simply generates a Chef::DelayedEvaluator instance to
prevent conflicts where attributes are expecting a block.

Dependent cookbooks

This cookbook has no specified dependencies.

Contingent cookbooks

ebs Applicable Versions
pkg-build Applicable Versions

No quality metric results found