Skip to content

Commit

Permalink
Php 8.4 (#215)
Browse files Browse the repository at this point in the history
* php 8.4
* fix entrypoint
* Apply suggestions from code review

Co-authored-by: Martin Stone <1611702+d7415@users.noreply.github.com>

---------

Co-authored-by: Martin Stone <1611702+d7415@users.noreply.github.com>
  • Loading branch information
ildyria and d7415 authored Jan 7, 2025
1 parent d73e485 commit 543b63c
Show file tree
Hide file tree
Showing 4 changed files with 25 additions and 17 deletions.
34 changes: 21 additions & 13 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -25,21 +25,29 @@ RUN \
apt-get update && \
apt-get upgrade -qy && \
apt-get install -qy --no-install-recommends\
ca-certificates \
curl \
apt-transport-https && \
curl -sSLo /tmp/debsuryorg-archive-keyring.deb https://packages.sury.org/debsuryorg-archive-keyring.deb && \
dpkg -i /tmp/debsuryorg-archive-keyring.deb && \
sh -c 'echo "deb [signed-by=/usr/share/keyrings/deb.sury.org-php.gpg] https://packages.sury.org/php/ bookworm main" > /etc/apt/sources.list.d/php.list' && \

apt-get update && \
apt-get install -qy --no-install-recommends \
adduser \
nginx-light \
php8.2-mysql \
php8.2-pgsql \
php8.2-sqlite3 \
php8.2-imagick \
php8.2-mbstring \
php8.2-gd \
php8.2-xml \
php8.2-zip \
php8.2-fpm \
php8.2-redis \
php8.2-bcmath \
php8.2-intl \
curl \
php8.4-mysql \
php8.4-pgsql \
php8.4-sqlite3 \
php8.4-imagick \
php8.4-mbstring \
php8.4-gd \
php8.4-xml \
php8.4-zip \
php8.4-fpm \
php8.4-redis \
php8.4-bcmath \
php8.4-intl \
libimage-exiftool-perl \
ffmpeg \
git \
Expand Down
2 changes: 1 addition & 1 deletion default.conf
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,7 @@ http {
# Mitigate https://httpoxy.org/ vulnerabilities
fastcgi_param HTTP_PROXY "";

fastcgi_pass unix:/run/php/php8.2-fpm.sock;
fastcgi_pass unix:/run/php/php8.4-fpm.sock;
fastcgi_index index.php;
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
fastcgi_param PHP_VALUE "post_max_size=100M
Expand Down
2 changes: 1 addition & 1 deletion entrypoint.sh
Original file line number Diff line number Diff line change
Expand Up @@ -168,5 +168,5 @@ echo "**** Start cron daemon ****"
service cron start

echo "**** Setup complete, starting the server. ****"
php-fpm8.2
php-fpm8.4
exec $@
4 changes: 2 additions & 2 deletions inject.sh
Original file line number Diff line number Diff line change
Expand Up @@ -308,6 +308,6 @@ if [ "$AWS_USE_PATH_STYLE_ENDPOINT" != '' ]; then
replace_or_insert "AWS_USE_PATH_STYLE_ENDPOINT" "$AWS_USE_PATH_STYLE_ENDPOINT"
fi
if [ "$PHP_TZ" != '' ]; then
sed -i "s|;*date.timezone =.*|date.timezone = ${PHP_TZ}|i" /etc/php/8.2/cli/php.ini
sed -i "s|;*date.timezone =.*|date.timezone = ${PHP_TZ}|i" /etc/php/8.2/fpm/php.ini
sed -i "s|;*date.timezone =.*|date.timezone = ${PHP_TZ}|i" /etc/php/8.4/cli/php.ini
sed -i "s|;*date.timezone =.*|date.timezone = ${PHP_TZ}|i" /etc/php/8.4/fpm/php.ini
fi

0 comments on commit 543b63c

Please # to comment.