Skip to content
Advertisement

Cannot Get Laravel Welcome Page to Show

My server is on DigitalOcean cloud. I am using Ubuntu with Apache web server. My home computer is running Windows 7. I am using putty for terminal.

Followed all of the directions on https://laracasts.com/series/laravel-5-fundamentals/episodes/1. Made it up to 8:40, where it directs you to run php -S localhost:8888 -t public. I run that, then open a web browser and tried the following:

http://mywebsite.com:8888
http://www.mywebsite.com:8888
http://mywebsite.com/learning-laravel-5/public
http://mywebsite.com/learning-laravel-5/public/index.php

None of the above work.

In Google Chrome, the first two options where I list the port number, I get a page saying This webpage is not available. ERR_CONNECTION_REFUSED. In IE, I just get a page with big font saying “This page can’t be displayed.”

For the last two options, I just get a completely blank page. In the console, I get this error: Failed to load resource: the server responded with a status of 500 (Internal Server Error).

I’m trying to pick up a web app framework to broaden my php skill set. Can someone help me out? What am I doing wrong/what is the video tutorial missing that I have to do in order to get Laravel up and running?

Advertisement

Answer

php -S localhost:8888 -t public is meant for running a site locally, which is what the video is showing.

If you are using a Digital Ocean droplet with Ubuntu and Apache, you will need to configure Apache to use /public as the document root and have Laravel installed in the /var/www directory.

From there you can visit the droplet’s IP address (http://XXX.XXX.XXX.XXX) instead of the domain name (unless you have configured the DNS for that domain name). You won’t need the port in the URL either, since Apache will be serving it on the default port 80.

User contributions licensed under: CC BY-SA
7 People found this is helpful
Advertisement