Skip to content

[lumen] Update to php 8.1 #6909

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Nov 12, 2021
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
2 changes: 1 addition & 1 deletion frameworks/PHP/lumen/benchmark_config.json
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
"database": "MySQL",
"framework": "lumen",
"language": "PHP",
"flavor": "PHP8",
"flavor": "PHP8.1",
"orm": "Full",
"platform": "FPM/FastCGI",
"webserver": "nginx",
Expand Down
10 changes: 5 additions & 5 deletions frameworks/PHP/lumen/lumen.dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -6,17 +6,17 @@ RUN apt-get update -yqq && apt-get install -yqq software-properties-common > /de
RUN LC_ALL=C.UTF-8 add-apt-repository ppa:ondrej/php
RUN apt-get update -yqq > /dev/null && \
apt-get install -yqq nginx git unzip \
php8.0-cli php8.0-fpm php8.0-mysql > /dev/null
RUN apt-get install -yqq php8.0-mbstring php8.0-xml > /dev/null
php8.1-cli php8.1-fpm php8.1-mysql > /dev/null
RUN apt-get install -yqq php8.1-mbstring php8.1-xml php8.1-dev > /dev/null

COPY --from=composer:latest /usr/bin/composer /usr/local/bin/composer

COPY deploy/conf/* /etc/php/8.0/fpm/
COPY deploy/conf/* /etc/php/8.1/fpm/

ADD ./ /lumen
WORKDIR /lumen

RUN if [ $(nproc) = 2 ]; then sed -i "s|pm.max_children = 1024|pm.max_children = 512|g" /etc/php/8.0/fpm/php-fpm.conf ; fi;
RUN if [ $(nproc) = 2 ]; then sed -i "s|pm.max_children = 1024|pm.max_children = 512|g" /etc/php/8.1/fpm/php-fpm.conf ; fi;

RUN composer install --optimize-autoloader --classmap-authoritative --no-dev --quiet

Expand All @@ -29,5 +29,5 @@ RUN chmod -R 777 /lumen

EXPOSE 8080

CMD service php8.0-fpm start && \
CMD service php8.1-fpm start && \
nginx -c /lumen/deploy/nginx.conf