Skip to content

Instantly share code, notes, and snippets.

@Zhann
Created March 25, 2015 10:49
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 Zhann/40d34357abc364b8aac3 to your computer and use it in GitHub Desktop.
Save Zhann/40d34357abc364b8aac3 to your computer and use it in GitHub Desktop.
recipe compile error
# sock::default recipe
chef_gem 'rest-client'
# libraries/sock.rb
class Chef::Recipe::Sock
require 'rest_client'
#.....
end
# error
# Compiling Cookbooks...
#
# ================================================================================
# Recipe Compile Error in /tmp/kitchen/cache/cookbooks/sock/libraries/sock.rb
# ================================================================================
#
# LoadError
# ---------
# cannot load such file -- rest_client
#
# Cookbook Trace:
# ---------------
# /tmp/kitchen/cache/cookbooks/sock/libraries/sock.rb:2:in `<class:Sock>'
# /tmp/kitchen/cache/cookbooks/sock/libraries/sock.rb:1:in `<top (required)>'
#
# Relevant File Content:
# ----------------------
# /tmp/kitchen/cache/cookbooks/sock/libraries/sock.rb:
#
# 1: class Chef::Recipe::Sock
# 2>> require 'rest_client'
# 3: attr_accessor :user, :node, :url
# 4: attr_writer :password
# 5:
#
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment