Move index.php to /public dir, so that I can isolate the file access
This commit is contained in:
parent
dabab56245
commit
0f61dd1bc6
@ -1,2 +1,3 @@
|
||||
[variables]
|
||||
NIXPACKS_PHP_FALLBACK_PATH = "/index.php"
|
||||
NIXPACKS_PHP_ROOT_DIR = "/app/public"
|
@ -1,9 +1,9 @@
|
||||
<?php declare(strict_types=1);
|
||||
|
||||
require_once __DIR__ . "/vendor/autoload.php";
|
||||
require_once __DIR__ . "/../vendor/autoload.php";
|
||||
|
||||
if (php_sapi_name() === "cli-server" && preg_match('/\.(?:png|jpg|jpeg|gif|css|ico|js|mjs|css\.map|webp)$/', $_SERVER["REQUEST_URI"])) {
|
||||
return false; // serve the requested resource as-is.
|
||||
}
|
||||
|
||||
require_once __DIR__ . "/src/app.php";
|
||||
require_once __DIR__ . "/../src/app.php";
|
Loading…
Reference in New Issue
Block a user