Laravel performs migration error

laravel execute command migration error message

[ErrorException]
Undefined index: APP_ENV

this error is reported whenever I use php artisan
what is the specific problem?

Mar.22,2021

solution 1:
prompt that there is no APP_ENV variable
the system configuration part of laravel is in the .env file, that is, the .env
of the project and directory is installed through composer without .evn file by default. You need to copy the .env.exmple file to .env to perform the migration normally.

solution 2:
if the above solution is not effective, it is recommended that you delete the vendor directory, which is the composer package directory, and then try to execute composer install again. Some systems need to add sudo sudo composer install

.

solution 3:
if the above two solutions are not valid, check whether your directory permissions are normal, and if normal, check whether you have permission to run php commands


has nothing to do with migration. Do you have no .env file for the project, or delete the APP_ENV configured in the .env file


if the env file exists and APP_ENV exists, I think there are two possibilities for reporting this error:

1, whether the file is readable
2, and whether the homestead or docker,.env file is copied to the virtual machine or image if used.

MySQL Query : SELECT * FROM `codeshelper`.`v9_news` WHERE status=99 AND catid='6' ORDER BY rand() LIMIT 5
MySQL Error : Disk full (/tmp/#sql-temptable-64f5-1be4b3d-31712.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
MySQL Errno : 1021
Message : Disk full (/tmp/#sql-temptable-64f5-1be4b3d-31712.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
Need Help?