I have a chef custom resource myresource.rb
resource_name :myresource
property :artifact_id, String
property :group_id, String
action :create do
Chef::Log.info("Package #{artifact_id} Group #{group_id}")
end
and i call it from coobook like this.
myresource 'myresource' do
artifact_id "artefict"
group_id "group"
end
but i get following error on that logging:
NameError: undefined local variable or method `artifact_id'
Any idea what might be wrong? I have also tried:
Chef::Log.info("Package #{:artifact_id} Group #{:group_id}")
Though this does not throw an error, it outputs:
Package artifact_id Group group_id
which is not correct.