Skip to content

Commit ee921b8

Browse files
authored
Add new recipe for phpstreamserver/symfony (#1749)
1 parent c640837 commit ee921b8

File tree

8 files changed

+40
-40
lines changed

8 files changed

+40
-40
lines changed

luzrain/phprunner-bundle/0.1/config/packages/phprunner.yaml

Lines changed: 0 additions & 12 deletions
This file was deleted.

luzrain/phprunner-bundle/0.1/manifest.json

Lines changed: 0 additions & 8 deletions
This file was deleted.

luzrain/phpstreamserver-bundle/0.2/config/packages/phpstreamserver.yaml

Lines changed: 0 additions & 12 deletions
This file was deleted.

luzrain/phpstreamserver-bundle/0.2/manifest.json

Lines changed: 0 additions & 8 deletions
This file was deleted.

phpstreamserver/symfony/0.4/bin/phpss

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
#!/usr/bin/env php
2+
<?php
3+
4+
use App\Kernel;
5+
use PHPStreamServer\Symfony\PHPStreamServerRuntime;
6+
7+
$_SERVER['APP_RUNTIME'] = PHPStreamServerRuntime::class;
8+
9+
require_once \dirname(__DIR__).'/vendor/autoload_runtime.php';
10+
11+
return function (array $context) {
12+
return new Kernel($context['APP_ENV'], (bool) $context['APP_DEBUG']);
13+
};
Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
<?php
2+
3+
use PHPStreamServer\Core\ReloadStrategy\ExceptionReloadStrategy;
4+
use PHPStreamServer\Core\Server;
5+
use PHPStreamServer\Symfony\Worker\SymfonyHttpServerProcess;
6+
7+
return static function (Server $server): void {
8+
$server->addWorker(new SymfonyHttpServerProcess(
9+
listen: '0.0.0.0:8080',
10+
reloadStrategies: [
11+
new ExceptionReloadStrategy(),
12+
],
13+
));
14+
};
Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
{
2+
"bundles": {
3+
"PHPStreamServer\\Symfony\\PHPStreamServerBundle": ["all"]
4+
},
5+
"copy-from-recipe": {
6+
"bin/": "%BIN_DIR%/",
7+
"config/": "%CONFIG_DIR%/"
8+
}
9+
}
Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
* You're ready to run your Symfony application with PHPStreamServer!
2+
Run <comment>bin/phpss start</> command to get started
3+
4+
* <fg=blue>Read</> the documentation at <comment>https://phpstreamserver.dev/docs/general/</>

0 commit comments

Comments
 (0)