Solving Laravel Homestead 504 Errors

Sometimes installing OctoberCMS using the wizard, or updating the system on a Laravel Homestead VM doesn't work out of the box with nginx. There's a default setting (of nginx) that caused me some problems initially, here's how to fix it.

The solution

  1. SSH into your virtual machine. I use the nice vm alias described here.

  2. Edit the /etc/nginx/nginx.conf file
sudo vim /etc/nginx/nginx.conf

Add this line to the http section:

fastcgi_read_timeout 300;

You may need to increase the timeout, but 300 worked for me.

  1. Restart nginx
sudo service nginx restart

Now the install wizard and system / plugin updates for OctoberCMS should work correctly on the Homestead VM!

Here's a snippet of what the changed nginx.conf file should look like:

http {


# Basic Settings


# This is the line we added

fastcgi_read_timeout 300;

sendfile on;

tcp_nopush on;

tcp_nodelay on;

keepalive_timeout 65;

types_hash_max_size 2048;



Next Post

Blog Comments powered by Disqus.