2

I created a laravel application and would like to deploy it to a new environment. I cloned my repository and ran 'composer install'. I also configured the .env with the new database settings. When I try to access the website there is a Server error 500. The following error is in the apache error_log.

[Tue Jan 26 12:52:24.876800 2016] [:error] [pid 16531] [client xx.xx.xx.xx:12499] PHP Fatal error:  require(): Failed opening required '/var/www/html/bootstrap/../vendor/autoload.php' (include_path='.:/usr/lib/php') in /var/www/html/bootstrap/autoload.php on line 17
[Tue Jan 26 12:55:44.302563 2016] [:error] [pid 16529] [client xx.xx.xx.xx:1615] PHP Warning:  require(/var/www/html/bootstrap/../vendor/autoload.php): failed to open stream: Permission denied in /var/www/html/bootstrap/autoload.php on line 17

Any clue what might be wrong or to look for next? Composer update runs fine:

server:/var/www/html$ composer install
Loading composer repositories with package information
Installing dependencies (including require-dev) from lock file
Nothing to install or update
Generating autoload files
1
  • have you give permissions to storage folder..if not then do chmod 777 -fR path/to/storage/folder Commented Jan 26, 2016 at 12:13

1 Answer 1

1

Issue is related to the apache user rights. I fixed the issue with the following command:

sudo chown www-data:www-data * -R
Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.