Skip to content

Latest commit

History

3 Commits

Folders and files

NameName
Last commit message
Last commit date

Repository files navigation

garveen/fastcgi-react

Simply serve fastcgi with reactphp

composer require garveen/fastcgi-react
require'vendor/autoload.php';
$loop = React\EventLoop\Factory::create();
$socket = newReact\Socket\Server(9000, $loop);
$fastcgi = newGarveen\FastCgi\React($socket);
// see http://www.php-fig.org/psr/psr-7/$fastcgi->onRequest = function (Psr\Http\Message\RequestInterface$request) {
returnnewGarveen\FastCgi\Response(
'200', // status code
['x-powered-by' => 'garveen/fastcgi-react'], // headers'Hello World!'// body
);
};
$loop->run();

About

Simply serve fastcgi with reactphp

Resources

Stars

10 stars

Watchers

2 watching

Forks

Releases

Packages

Used by

Contributors

Languages