Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 6 additions & 5 deletions docs/best-practices/deployment.md
Original file line number Diff line number Diff line change
Expand Up @@ -414,11 +414,11 @@ Additionally, the default [event loop implementation](https://github.com/reactph
in Framework X uses the `select()` system call, which is also limited to 1024
file descriptors on most systems (`PHP_FD_SETSIZE` constant). If you want to use a
higher limit, you need to install one of the supported event loop extensions
from PECL:
using [PIE](https://github.com/php/pie):

* [`ext-ev`](https://pecl.php.net/package/ev) (recommended)
* [`ext-event`](https://pecl.php.net/package/event)
* [`ext-uv`](https://pecl.php.net/package/uv) (beta)
* [`ext-ev`](https://packagist.org/packages/osmanov/pecl-ev) (recommended)
* [`ext-event`](https://packagist.org/packages/osmanov/pecl-event)
* [`ext-uv`](https://packagist.org/packages/amphp/uv) (beta)

Besides your `ulimit` setting, no further configuration is required – these
extensions will automatically be loaded when available. So, whether your
Expand Down Expand Up @@ -716,9 +716,10 @@ be achieved by using a `Dockerfile` with the following contents:
# base build stage with build tools to compile extensions in parallel
FROM php-version AS phpize
RUN apk --no-cache add --virtual .phpize-deps autoconf gcc libc-dev linux-headers make
COPY --from=ghcr.io/php/pie:1-bin /pie /usr/local/bin/pie

FROM phpize AS ext-ev
RUN MAKEFLAGS="-j$(nproc)" pecl install ev && docker-php-ext-enable ev
RUN pie install osmanov/pecl-ev

FROM phpize AS ext-sockets
RUN docker-php-ext-install -j$(nproc) sockets
Expand Down
3 changes: 2 additions & 1 deletion tests/integration/Dockerfile-production
Original file line number Diff line number Diff line change
Expand Up @@ -12,9 +12,10 @@ COPY vendor/ vendor/
# base build stage with build tools to compile extensions in parallel
FROM php-version AS phpize
RUN apk --no-cache add --virtual .phpize-deps autoconf gcc libc-dev linux-headers make
COPY --from=ghcr.io/php/pie:1-bin /pie /usr/local/bin/pie

FROM phpize AS ext-ev
RUN MAKEFLAGS="-j$(nproc)" pecl install ev && docker-php-ext-enable ev
RUN pie install osmanov/pecl-ev

FROM phpize AS ext-sockets
RUN docker-php-ext-install -j$(nproc) sockets
Expand Down