RuntimeException vendor does not exist and could not be created

Googlers, do not use composer with sudo:

Add your user in the www-data group (this action require you to logout and login again)

sudo usermod -a -G www-data `whoami`

Give the right permissions to /var/www

sudo chown root:root /var/www
sudo chmod 755 /var/www/

Give these permissions to your project

sudo chown -R www-data:www-data /var/www/<project>
sudo chmod -R 774 /var/www/<project>

Leave a Comment

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)