Skip to content

Commit

Permalink
Added jemalloc to Alpine build.
Browse files Browse the repository at this point in the history
  • Loading branch information
Bilge committed Nov 19, 2023
1 parent 651c483 commit 87b19e1
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion Alpine.Dockerfile
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
FROM php:8.2.12-fpm-alpine

RUN \
apk add icu icu-dev libxslt libxslt-dev libffi libffi-dev libpq libpq-dev gmp gmp-dev \
apk add icu icu-dev jemalloc libxslt libxslt-dev libffi libffi-dev libpq libpq-dev gmp gmp-dev \
&& docker-php-ext-install opcache \
# Number formatting in our own application templates requires intl.
intl \
Expand All @@ -22,6 +22,9 @@ RUN \
# All dev packages can be removed post-compile, however the main packages cannot.
&& apk del icu-dev libxslt-dev libffi-dev libpq-dev gmp-dev

# Replace the slow musl allocator.
ENV LD_PRELOAD=libjemalloc.so.2

# Install Composer.
RUN wget https://raw.githubusercontent.com/composer/getcomposer.org/main/web/installer -qO- |\
php -- --install-dir /usr/local/bin --filename composer

0 comments on commit 87b19e1

Please sign in to comment.