remote_file error


#1

Hi,

I am not able to create files in directories other than ‘/tmp’ using a chef
recipe.

I have used the following code and it fails:

template “/etc/qs/deep_thought.txt” do
source "deep_thought.txt.erb"
variables :deep_thought => node[:deep_thought]
action :create
end

Running ‘mysql’ recipe (mysql cookbook from opscode site) on the client also
displays a similar error as the file ‘/etc/mysql/grants.sql’ is not created.

I even tried setting the permissions of folder ‘/etc’ to ‘777’ but it still
failed to create the file.

Please let me know what needs to be done to resolve this issue.

Thanks
RBF


#2

Hello,

On 2 February 2010 21:32, rijufrancis@gmail.com wrote:

I am not able to create files in directories other than ‘/tmp’ using a chef
recipe.

Are you running chef on a system that has an enhanced security system
in place like AppArmor on Ubuntu? If you have, then next to the basic
file permissions, all access to resources on your system are monitored
by the use of profiles.

Disable AppArmor (1) and retry running the recipes.

(1) https://help.ubuntu.com/community/AppArmor

Ringo