Refactor configuration handling: implement dynamic loading of config and cache paths for improved security and flexibility in Docker environments

This commit is contained in:
David Dyer committed 2026-10-25 16:49:43 -04:00
1 parent c7b836bcf2
commit bb65ecd43c
7 files changed
+53 -12

No files matched your search

+11
View File
@@ -0,0 +1,11 @@
<?php
declare(strict_types=1);
/**
* Loads the site config. In Docker, FITZ_CONFIG_PATH points outside the
* web root (see docker-compose.yaml), so a deploy that replaces www/ can
* never overwrite or ship it. Local dev falls back to config.php in the
* project root.
*/
require getenv('FITZ_CONFIG_PATH') ?: __DIR__ . '/../config.php';