Skip to content

Instantly share code, notes, and snippets.

@tmatilai
Forked from matschaffer/solo.rb
Last active February 28, 2018 22:01
Show Gist options
  • Save tmatilai/4434030 to your computer and use it in GitHub Desktop.
Save tmatilai/4434030 to your computer and use it in GitHub Desktop.
knife[:solo_path] = 'chef-solo' # relative to $HOME, but can be '/tmp/chef-solo' etc.
# knife-solo sets the KNIFE_SOLO variable when runnin on the work station
solo_path = ENV['KNIFE_SOLO'] ? knife[:solo_path] : File.expand_path(File.dirname(__FILE__))
data_bag_path File.join(solo_path, 'data_bags')
encrypted_data_bag_secret File.join(solo_path, 'data_bag_key')
cookbook_path [ File.join(solo_path, "site-cookbooks"),
File.join(solo_path, "cookbooks") ]
role_path File.join(solo_path, "roles")
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment