I am struggling to delete a file in production mode.I have tried several options that are
1) File.delete(filename)
2) FileUtils.rm_rf(filename)
It says permission denied in production mode when i run in development it works fine.Also when i explicitly run chmod -R 777 on the folder where the file exists it lets me delete the file.I have tried with File.chmod option but it isn't working