{"id":20113740,"url":"https://github.com/php-pm/php-pm-drupal","last_synced_at":"2025-05-06T12:30:36.719Z","repository":{"id":57039889,"uuid":"45074798","full_name":"php-pm/php-pm-drupal","owner":"php-pm","description":"Drupal adapter for use of Drupal 8 with PHP-PM","archived":false,"fork":false,"pushed_at":"2017-03-10T20:04:31.000Z","size":48,"stargazers_count":43,"open_issues_count":7,"forks_count":2,"subscribers_count":9,"default_branch":"master","last_synced_at":"2025-04-09T12:21:53.848Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"PHP","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/php-pm.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2015-10-27T22:45:37.000Z","updated_at":"2025-03-07T12:15:03.000Z","dependencies_parsed_at":"2022-08-24T00:50:48.942Z","dependency_job_id":null,"html_url":"https://github.com/php-pm/php-pm-drupal","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/php-pm%2Fphp-pm-drupal","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/php-pm%2Fphp-pm-drupal/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/php-pm%2Fphp-pm-drupal/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/php-pm%2Fphp-pm-drupal/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/php-pm","download_url":"https://codeload.github.com/php-pm/php-pm-drupal/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":252683379,"owners_count":21788028,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-11-13T18:25:37.472Z","updated_at":"2025-05-06T12:30:36.423Z","avatar_url":"https://github.com/php-pm.png","language":"PHP","readme":"# PHP-PM DrupalKernel Adapter\n\n## Overview\n\nThis is a fork of PHP-PM's HttpKernel adapter for integrating Drupal with PHP-PM (therefore, also with ReactPHP).\n\nThe primary components are a bootstrap and bridge.\n\nSee:\n* https://github.com/php-pm/php-pm\n* https://github.com/php-pm/php-pm-httpkernel\n* http://marcjschmidt.de/blog/2014/02/08/php-high-performance.html\n\nThe code is in alpha -- very experimental.  Last tested against `drupal-8.0.2`.\n\nView / report issues at https://github.com/php-pm/php-pm-drupal/issues.\n\n### Setup / Usage\n\n  1. Install Drupal.\n\n  2. From the Drupal web root, install this project with composer: `composer require php-pm/drupal-adapter`.\n\n  This will also install PHP-PM and the default React \u003c-\u003e Symfony bridge (php-pm/httpkernel-adapter).\n\n  3. Apply these patches to Drupal core:\n    * `vendor/kentr/php-pm-drupal-adapter/patches/kentr-allow-repeated-setSitePath-in-DrupalKernel.patch`\n    * `vendor/kentr/php-pm-drupal-adapter/patches/stop_using-2505339-24.patch`\n\n  4. Start php-pm with\n\n```bash\n\u003cabsolute path to web root\u003e/vendor/bin/ppm \\\nstart \\\n\u003cabsolute path to web root\u003e \\\n--bridge=httpKernel \\\n--bootstrap=PHPPM\\\\Bootstraps\\\\Drupal\n```\n\nExample:\n```bash\n/var/www/html/vendor/bin/ppm \\\nstart \\\n/var/www/html/ \\\n--bridge=httpKernel \\\n--bootstrap=PHPPM\\\\Bootstraps\\\\Drupal\n```\n\n## DrupalKernel bridge\nBy default, PHP-PM uses the `\\PHPPM\\Bridges\\HttpKernel` bridge to convert a ReactPHP request into a Symfony request and the Symfony response into a ReactPHP response.\n\nThe included `\\PHPPM\\Bridges\\DrupalKernel` bridge extends `\\PHPPM\\Bridges\\HttpKernel` to populate various request meta-variables specified by [CGI/1.1 (RFC 3875)](http://www.faqs.org/rfcs/rfc3875.html).\n\n### Setup / Usage\n\n  1. Install as described above.\n\n  2. Include the environment variables and the `--bridge` option in the php-pm start command.\n\n    Supported environment variables:\n    * **SCRIPT_NAME:** '/index.php' to emulate a standard setup where web requests execute Drupal's `index.php` script.\n    * **SERVER_NAME:** Your site's server / domain name.  If you're using trusted host settings (`$settings['trusted_host_patterns']` in `settings.php`), this must match one of the trusted hosts.\n    * **SERVER_ADDRESS:** IP address of the server.\n    * **DOCUMENT_ROOT:** Absolute filepath of the web root directory.\n\nExample:\n\n```bash\nSCRIPT_NAME=/index.php \\\nSERVER_NAME=localhost \\\nSERVER_ADDRESS=127.0.0.1 \\\nDOCUMENT_ROOT=/var/www/html \\\n/var/www/html/vendor/bin/ppm start /var/www/html \\\n--bridge=PHPPM\\\\Bridges\\\\DrupalKernel \\\n--bootstrap=PHPPM\\\\Bootstraps\\\\Drupal\n```\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fphp-pm%2Fphp-pm-drupal","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fphp-pm%2Fphp-pm-drupal","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fphp-pm%2Fphp-pm-drupal/lists"}