7

I have been trying to deploy a Rail 3.1.1 app on CentOS 6

This is the error I am getting

Error Compiling CSS
Errno::ENOENT: No Such File or Directory - /var/www/vhosts/MySite/MyAPP/tmp/cache/assets/sprockets%t43t34t34t...t34t-r32r-r23.lock

/usr/local/lib/ruby/1.9.1/tempfile.rb:343:in 'rmdir'

I appreciate the help.

Steffan Perry
  • 2,112
  • 1
  • 21
  • 21

2 Answers2

22

There were actually 2 problems. First the permissions were wrong. and secondly like Nerian said, you have to clear your tmp folder.

To set the correct permissions

chown apache.root yourapp -R
chmod 755 yourapp -R

To clear you tmp folder

rake tmp:pids:clear             
rake tmp:sessions:clear
rake tmp:sockets:clear
rake tmp:cache:clear
Steffan Perry
  • 2,112
  • 1
  • 21
  • 21
0

If you are using an Apache server you simply need to make sure the apache account www-data can make executions in the directory.

chown -R www-data:www-data .
service apache2 reload
Timothy
  • 4,198
  • 6
  • 49
  • 59