joanhey / AdapterMan

Run almost any PHP app faster and asynchronously with Workerman, without touch 1 line of code in your fw or app. Also use it as Serverless.
https://twitter.com/adaptermanphp
MIT License
751 stars 48 forks source link

How to modify start.php if using symfony6? #37

Open cfftony opened 1 year ago

cfftony commented 1 year ago

The original index.php is in the public directory:

use App\Kernel;

require_once dirname(DIR).'/vendor/autoload_runtime.php';

return function (array $context) { return new Kernel($context['APP_ENV'], (bool) $context['APP_DEBUG']); };

it's very different with https://github.com/joanhey/AdapterMan/blob/master/recipes/symfony.md

How to modify it?

Thanks.

joanhey commented 1 year ago

You can use the actual recipe. The Symfony demo blog in the video, it's using v6.1.6. Laravel it's using v6.2.x with the old Front Controller.

The Symfony people are changing it, to move all the people to use their Runtime front controller. In reality the Symfony Runtime and Laravel Octane, do the same think, but each one try to move the community to theirs frameworks, and for that they are doing in small different ways and name.

But we need to adapt Adapterman to the new Front Controller, for the future.