0

I'm in the process of getting a Laravel 5 app working on Azure Web Apps and am encountering an issue via Laravel's temporary storage.

Any time a template renders, Laravel attempts to cache it to the local filesystem. Unfortunately, for some reason Laravel doesn't have permission to write to its storage directory.

  • I am deploying my application from my build server via FTP
  • I am running on the free-tier shared infrastructure (just while I'm getting set up)
  • My deployment server is running Linux

In this circumstance, it's obvious what the problem is. Unfortunately, what I don't understand is why my web server doesn't have access to write to the directories my FTP user uploads.

Ideally any solution offered will be one that I can automate as part of my deploy process.

Alexander Trauzzi
  • 7,277
  • 13
  • 68
  • 112

1 Answers1

-1

According to http://clivern.com/working-with-laravel-caching/, you can change the directory of the cache files using the cache.php configuration file. I'd like to suggest you to use $_SERVER['DOCUMENT_ROOT'] to obtain the root folder of your web app, and then construct a path for the cache files.

Ming Xu - MSFT
  • 2,116
  • 1
  • 11
  • 13