Skip to content

[php-orm] Update to php 8.1 #6911

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 2 commits 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
4 changes: 2 additions & 2 deletions frameworks/PHP/php/benchmark_config.json
Original file line number Diff line number Diff line change
Expand Up @@ -148,7 +148,7 @@
"database": "MySQL",
"framework": "None",
"language": "PHP",
"flavor": "PHP7",
"flavor": "PHP8.1",
"orm": "Full",
"platform": "FPM/FastCGI",
"webserver": "nginx",
Expand All @@ -167,7 +167,7 @@
"database": "MySQL",
"framework": "None",
"language": "PHP",
"flavor": "PHP7",
"flavor": "PHP8.1",
"orm": "Micro",
"platform": "FPM/FastCGI",
"webserver": "nginx",
Expand Down
9 changes: 5 additions & 4 deletions frameworks/PHP/php/php-eloquent.dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -5,16 +5,16 @@ ARG DEBIAN_FRONTEND=noninteractive
RUN apt-get update -yqq && apt-get install -yqq software-properties-common > /dev/null
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 php8.0-common php8.0-cli php8.0-fpm php8.0-mysql php8.0-mbstring > /dev/null
apt-get install -yqq nginx git unzip php8.1 php8.1-common php8.1-cli php8.1-fpm php8.1-mysql php8.1-mbstring 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 ./ /php
WORKDIR /php

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;

COPY deploy/eloquent/composer* ./
RUN composer install --optimize-autoloader --classmap-authoritative --no-dev --quiet
Expand All @@ -23,5 +23,6 @@ RUN chmod -R 777 /php

EXPOSE 8080

CMD service php8.0-fpm start && \
CMD service php8.1-fpm start && \
nginx -c /php/deploy/nginx7.conf -g "daemon off;"

8 changes: 4 additions & 4 deletions frameworks/PHP/php/php-laravel-query-builder.dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -5,16 +5,16 @@ ARG DEBIAN_FRONTEND=noninteractive
RUN apt-get update -yqq && apt-get install -yqq software-properties-common > /dev/null
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 php8.0-common php8.0-cli php8.0-fpm php8.0-mysql php8.0-mbstring > /dev/null
apt-get install -yqq nginx git unzip php8.1 php8.1-common php8.1-cli php8.1-fpm php8.1-mysql php8.1-mbstring 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 ./ /php
WORKDIR /php

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;

COPY deploy/eloquent/composer* ./
RUN composer install --optimize-autoloader --classmap-authoritative --no-dev --quiet
Expand All @@ -23,5 +23,5 @@ RUN chmod -R 777 /php

EXPOSE 8080

CMD service php8.0-fpm start && \
CMD service php8.1-fpm start && \
nginx -c /php/deploy/nginx7.conf -g "daemon off;"