Reloading .env variables without restarting server (Laravel 5, shared hosting)

前端 未结 7 2128
旧巷少年郎
旧巷少年郎 2020-12-23 13:46

My Laravel 5 has run OK until the database was configured, then found this error:

SQLSTATE[HY000] [2002] php_network_getaddresses: getaddrinfo failed: Name o         


        
7条回答
  •  醉梦人生
    2020-12-23 14:31

    I know this is old, but for local dev, this is what got things back to a production .env file:

    rm bootstrap/cache/config.php
    

    then

    php artisan config:cache
    php artisan config:clear
    php artisan cache:clear
    

提交回复
热议问题