I am working with laravel 7 and after clone my existing repo which was created via windows operating system and right now i am using macOS. After cloning I copy .env.example and converted into .env file and then run the below commands,
composer install
npm install && npm run dev
php artisan key:generate
All of the above commands run perfectly and then i run the 4 number commands to seed the database.
php artisan migrate:fresh --seed
After run the php artisan migrate:fresh --seed
, I have faced an error [1045] Access denied for user 'root'@'localhost' (using password: NO) (SQL: SHOW FULL TABLES WHERE table_type = 'BASE TABLE')
Then I checked the php version and it showed php version: 8
and that's why I downgrade the php version from version 8 to 7.4
and right now the requires version are given below,
- PHP Version:
7.4.30
- Composer Version:
2.4.1
then I clone again and run the same commands 1,2,3 and 4 but iot's sorrow that I have faced same error again. Please check the attached file and check the error and help me to solve the error.