Timezones in Lumen
This blog post was originally published a little while ago. Please consider that it may no longer be relevant or even accurate.
Because there aren't any configuration files with Lumen, you now approach setting up the application using environment variables. If you dig into Lumen's source code you can find the configuration files where the framework attempts to load options from the environment and then falls back to it's defaults. However, the timezone option isn't actually listed in the config/app.php
configuration file.
No matter however, as you'll find in the Lumen Application
constructor it will also attempt to load the timezone from the environment:
So, setting the timezone up is as easy as popping APP_TIMEZONE
into your .env
configuration file as you normally would.