I have my Laravel 7 app uploaded on VPS server running on the subdomain. Everything is fine, index.php opens for the subdomain, I have generated an app key and installed composer packages.
Then I got 500 internal error. Here is a screenshot

The error has something to do with composer autoload.
Here is the list of things I tried doing.
php artisan cache:clear
composer update
Deleting vendor folder and running composer install