Hey everyone -
So I am working on deploying my first laravel app onto a bluehost server, and I'm running into some problems. I uploaded everything except the contents of the "public" folder to the root of the server, then I put the contents of "public" into "public_html". From here I changed the public path in "bootstrap/paths.php" to
'public' => __DIR__.'/../public_html',
So far this isn't working for me, and the error log is spitting out this -
[09-Apr-2014 09:04:02] PHP Fatal error: require() [<a href='function.require'>function.require</a>]: Failed opening required 'DIR/../bootstrap/autoload.php' (include_path='.:/usr/lib64/php:/usr/share/pear') in /home1/regmuel/public_html/index.php on line 21
I think I see part of the problem, but I'm not sure how to go about fixing it. Clearly the app isn't able to load the autoload.php file, but as far as I can tell the path give to require() should be correct?
Can anyone help me out on this one?
Just a quick addition - It looks like the bluehost servers are running PHP 5.4.24 so that shouldn't be the problem, even though it looks like DIR isn't being parsed correctly.
Hello!
I recently deployed a Laravel site to bluehost. Since I use my bluehost account for several sites, i have a subdirectory for each inside my /public_html directory. I deployed the entire laravel site to the subdirectory for my site, then I created a subdomain to point to the laravel /public folder for its document root.
so deploy to /public_html/mysite/ subdomain doc root=> /public_html/mysite/public
Then the laravel config works with its original settings.
antiquarian said:
Hello!
I recently deployed a Laravel site to bluehost. Since I use my bluehost account for several sites, i have a subdirectory for each inside my /public_html directory. I deployed the entire laravel site to the subdirectory for my site, then I created a subdomain to point to the laravel /public folder for its document root.
so deploy to /public_html/mysite/ subdomain doc root=> /public_html/mysite/public
that is what i have done and works nice.
Then the laravel config works with its original settings.
You can do this with .htaccess
Assuming your folder structure looks like:
public_html/
.htaccess
app/
public/
vendor/
bootstrap/
html/
...
...
...
Edit your .htaccess and add this:
RewriteEngine On
RewriteCond %{REQUEST_URI} !public/
RewriteRule ^(.*)$ /public/$1 [L]
Sign in to participate in this thread!
The Laravel portal for problem solving, knowledge sharing and community building.
The community