Is it a good idea to edit .env dynamically in Laravel 5?
问题 I am building an admin panel, so I need to make some core settings (like smtp settings, etc) of my Laravel 5 app configurable to end users through front-end interface. My initial thoughts were to use database as a settings storage alongside caching(to avoid issuing database calls every time a config value is accessed). However, it appears, that Facades are loaded after config files, thus the code below doesn't work: <?php // app/config/custom_settings.php return [ 'key' => Cache::get('key');