php - Laravel & VestaCP HTTP Error 500 -
i set vps on centos 7 vestacp, i've heard many great things it. great except can't run laravel project on it. i've followed couple of tutorials on how set laravel project on vestacp, doesn't anything.
i have contents of public
folder in public_html
, , have else in private/laravel
folder, outside of public_html
. edited index.php file include bootstrap/autoload
, bootstrap/app
when uploading projects hosting, time doesn't work @ all, , throws me http error 500.
my initial thoughts must apache permissions, didn't work @ all. if can me out @ all, i'd grateful.
the error occurs because php not given access private/laravel
directory. can check in logs in /var/log/httpd/domains/yourdomain.com.error.log
. if log message says open_basedir restriction in effect
can confirm problem.
to resolve need add private/laravel
directory open_basedir path in /home/username/conf/web/httpd.conf
, /home/username/conf/web/shttpd.conf
.
- in
.conf
file, find listing corresponding domain error occurs. - append path line
php_admin_value open_basedir /home/username/web/yourdomain.com/public_html:/home/username/tmp
. - after appending path line
php_admin_value open_basedir /home/username/web/yourdomain.com/public_html:/home/username/tmp:/home/username/web/yourdomain.com/private/laravel
. - save , exit.
- now restart apache server
service httpd restart
.
Comments
Post a Comment