Files
InvoiceShelf/config/app.php
T
Darko Gjorgjijoski 2cf3b3e840 fix(config): make the application timezone configurable (#706)
Backport of InvoiceShelf/InvoiceShelf#703 to 2.x.
Fixes InvoiceShelf/docker#64.

Two bugs compounded so that no supported value had any effect. config/app.php
had no timezone key, so Laravel's own fallback won — and that fallback is a
literal 'UTC' string, not an env() lookup, leaving APP_TIMEZONE inert despite
shipping in .env.example. inject.sh then wrote a bare TIMEZONE key that nothing
reads, so the documented container variable did nothing either.

inject.sh now writes APP_TIMEZONE and accepts either spelling, so existing
compose files keep working unchanged.
2026-07-29 12:37:07 +02:00

37 lines
1.1 KiB
PHP

<?php
use Illuminate\Support\Facades\Facade;
return [
/*
|--------------------------------------------------------------------------
| Application Timezone
|--------------------------------------------------------------------------
|
| The default timezone for date and date-time functions. Laravel's own
| fallback is the literal string 'UTC' rather than an env() lookup, so
| without this key APP_TIMEZONE has no effect at all and scheduled tasks
| and recurring invoices always run on UTC.
|
*/
'timezone' => env('APP_TIMEZONE', 'UTC'),
/*
|--------------------------------------------------------------------------
| Class Aliases
|--------------------------------------------------------------------------
|
| This array of class aliases will be registered when this application
| is started. You may add any additional class aliases which should
| be loaded to the array. For speed, all aliases are lazy loaded.
|
*/
'aliases' => Facade::defaultAliases()->merge([
'Menu' => Lavary\Menu\Facade::class,
])->toArray(),
];