forked from laysense/laysite
19 lines
486 B
PHP
Executable File
19 lines
486 B
PHP
Executable File
#!/usr/bin/env php
|
|
<?php
|
|
|
|
declare(strict_types=1);
|
|
|
|
chdir(__DIR__);
|
|
require __DIR__ . '/vendor/autoload.php';
|
|
|
|
// Read process variables before Webman loads .env in the worker bootstrap.
|
|
App\Config\Environment::load();
|
|
|
|
$sessionPath = __DIR__ . '/runtime/sessions';
|
|
if (!is_dir($sessionPath) && !mkdir($sessionPath, 0750, true) && !is_dir($sessionPath)) {
|
|
throw new RuntimeException('无法创建会话目录。');
|
|
}
|
|
ini_set('session.save_path', $sessionPath);
|
|
|
|
support\App::run();
|