On a git pull from remote dev environment to a staging environment running off AWS server... I was greeted with the white screen of death. While it took me a while to resolve the actual issue, my action plan was as follows:
How to resolve:
- Look in your log files;
- Add a few lines to your index.php file
Log files
If you have access via ssh they are usually located in /var/log. To quickly which files have been updated / altered recently, run the following command when you are in the log files
ls -lht
This will list the files in a single column, ordered by time descending from the top.
Unfortunately, the log files gave me no further clues. There were no errors showing around the time that I was running the query.
index.php + a few more lines
In my situation the log files were of no assistance. Steps two requires editing the index.php file. I added the following to the top of my index.php file and reloaded the page:
error_reporting(E_ALL); ini_set('display_errors', TRUE); ini_set('display_startup_errors', TRUE);
Refreshing the page showed the error on load. In my case, the error was instigated from the call in the index.php file. It called autoload.php
autoload.php in a standard environment look like:
return require __DIR__ . '/vendor/autoload.php';
But as I'm running Docker with a web/ instance my local looks like:
return require __DIR__ . '/../vendor/autoload.php';
The second is correct locally and stops there. Not for the dev or staging environments.