Naj*_*idi 5 file environment-variables laravel laravel-4
DB_CONNECTION=mysql
DB_HOST=127.0.0.1
DB_PORT=3306
DB_DATABASE=
DB_USERNAME=root
DB_PASSWORD=
Run Code Online (Sandbox Code Playgroud)
这是我对 laravel 5.4 的配置,但 php artisan migrate 不工作并且有错误和迁移错误
Users-MacBook-Pro: ATP Developers php artisan migrate
In Connection.php line 664:
SQLSTATE[HY000] [1045] Access denied for user ''@'localhost' (using password: NO) (SQL: select * from information_schema.tables where table schema = atp_db and table_name = migrations)
In Connector.php line 87:
SQLSTATE[HY000] [1045] Access denied for user ''@'localhost' (using password: NO)
Run Code Online (Sandbox Code Playgroud)
我遇到了类似的问题。因此,我运行https://laracasts.com/discuss/channels/general-discussion/env-file-and-config-keys-not-updating-after-change中提到的以下命令
,
php artisan cache:clear
php artisan config:clear
php artisan route:clear
另外,请确保重新启动服务器
php artisan serve
Run Code Online (Sandbox Code Playgroud)
归档时间: |
|
查看次数: |
7630 次 |
最近记录: |