Skip to content

Commit 900ca9d

Browse files
committed
Merge branch 'develop' for v4.7.0
2 parents de9e5d1 + 04cf8a0 commit 900ca9d

File tree

15 files changed

+2122
-18
lines changed

15 files changed

+2122
-18
lines changed

.github/workflows/test_and_publish.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ jobs:
2020
strategy:
2121
fail-fast: false
2222
matrix:
23-
php: ['7.4', '8.0', '8.1', '8.2', 'stable']
23+
php: ['7.4', '8.0', '8.1', '8.2', '8.3', 'stable']
2424
steps:
2525
- name: Checkout
2626
uses: actions/checkout@v3

cron/Dockerfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
FROM mcuadros/ofelia@sha256:4d67a32724f5a57393c9aca0b6731cce60b6a5b91bd369b8e41cbede2e09a3e1
1+
FROM mcuadros/ofelia@sha256:9478fec5cbcbad325c01b3d76523d44ebccb7f62c153c1389335a0a46f05c58e
22
LABEL org.label-schema.schema-version="1.0.0-rc1"
33
LABEL org.label-schema.vendor="EasyEngine"
44
LABEL org.label-schema.name="cron"

newrelic-daemon/Dockerfile

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,4 @@
1-
# alpine:latest at 2023-11-10T14:09:58IST
2-
FROM alpine@sha256:eece025e432126ce23f223450a0326fbebde39cdf496a85d8c016293fc851978
1+
FROM alpine@sha256:c5b1261d6d3e43071626931fc004f70149baeba2c8ec672bd4f27761f8e1ad6b
32

43
LABEL maintainer="Riddhesh Sanghvi <riddhesh237@gmail.com>"
54
LABEL org.label-schema.schema-version="1.0.0"

nginx-proxy/Dockerfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
FROM jwilder/nginx-proxy:1.0.3@sha256:459d84702195bebc427202ba91c41aa95ccf5e5a112db2e0d0ca9b2231cd2fb8
1+
FROM jwilder/nginx-proxy:1.5.1@sha256:272e8aa11597fe1d9b170aa858dc3bf48a62e8dacc4890bdb1d4c28ac51e07d9
22
LABEL org.label-schema.schema-version="1.0.0"
33
LABEL org.label-schema.vendor="EasyEngine"
44
LABEL org.label-schema.name="nginx-proxy"

nginx/Dockerfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
FROM openresty/openresty:1.21.4.2-buster@sha256:c1ecc876f6339696b1d9b9a3f0735ff814f758e5eb966bdfc26966172e27d0b8
1+
FROM openresty/openresty:1.25.3.1-buster@sha256:362e0e52cd5eabb76bafb0741889cb79fc28c64504dc882827b091987d4ae8aa
22
LABEL org.label-schema.schema-version="1.0.0"
33
LABEL org.label-schema.vendor="EasyEngine"
44
LABEL org.label-schema.name="nginx"

php/8.2/Dockerfile

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -96,15 +96,14 @@ ln -s /usr/local/etc/misc/msmtprc /etc/msmtprc && \
9696
chown www-data:www-data /usr/local/etc/misc/msmtprc && \
9797
chown www-data:www-data /etc/msmtprc
9898

99-
## Newrelic agent does not support PHP 8.2 as of 6th Feb 2023. So, we are commenting it out for now.
100-
# RUN latest_build=$(curl -s https://download.newrelic.com/php_agent/release/ | grep 'linux.tar.gz' | sed 's/.*"\(.*\)".*/\1/') && \
101-
# curl -L "https://download.newrelic.com$latest_build" | tar -C /tmp -zx && \
102-
# export NR_INSTALL_USE_CP_NOT_LN=1 && \
103-
# export NR_INSTALL_SILENT=1 && \
104-
# /tmp/newrelic-php5-*/newrelic-install install && \
105-
# rm -rf /tmp/newrelic-php5-* /tmp/nrinstall*
99+
RUN latest_build=$(curl -s https://download.newrelic.com/php_agent/release/ | grep 'linux.tar.gz' | sed 's/.*"\(.*\)".*/\1/') && \
100+
curl -L "https://download.newrelic.com$latest_build" | tar -C /tmp -zx && \
101+
export NR_INSTALL_USE_CP_NOT_LN=1 && \
102+
export NR_INSTALL_SILENT=1 && \
103+
/tmp/newrelic-php5-*/newrelic-install install && \
104+
rm -rf /tmp/newrelic-php5-* /tmp/nrinstall*
106105

107-
# ENV NR_PORT=/run/newrelic/newrelic.sock
106+
ENV NR_PORT=/run/newrelic/newrelic.sock
108107

109108
# Setup logs
110109
RUN mkdir -p /var/log/php; \
@@ -117,7 +116,8 @@ COPY expose_off.ini /usr/local/etc/php/conf.d/expose_off.ini
117116
COPY bashrc /root/.bashrc
118117
COPY bashrc /var/www/.bashrc
119118
COPY docker-entrypoint.sh /usr/local/bin/
120-
# COPY newrelic.ini /usr/local/etc/php/conf.d/newrelic.ini
119+
COPY newrelic.ini /usr/local/etc/php/conf.d/newrelic.ini
120+
COPY newrelic.ini /data/newrelic.ini
121121

122122
WORKDIR /var/www/htdocs
123123
USER www-data

php/8.3/Dockerfile

Lines changed: 125 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,125 @@
1+
FROM php:8.3-fpm@sha256:136ef3a7ce42b2892be36b6958e77549bbd423ae8ed3615b8717da60d95c5c2b
2+
LABEL maintainer="Riddhesh Sanghvi <riddhesh237@gmail.com>, Devarshi Sathiya <devarshisathiya5@gmail.com>"
3+
LABEL org.label-schema.schema-version="1.0.0"
4+
LABEL org.label-schema.vendor="EasyEngine"
5+
LABEL org.label-schema.name="php"
6+
7+
RUN set -ex; \
8+
apt-get update; \
9+
apt-get install -y --no-install-recommends \
10+
imagemagick \
11+
less \
12+
mariadb-client msmtp \
13+
libc-client-dev \
14+
libfreetype6-dev \
15+
libjpeg-dev \
16+
libjpeg62-turbo-dev \
17+
libkrb5-dev \
18+
libmagickwand-dev \
19+
libgraphicsmagick1-dev \
20+
libmcrypt-dev \
21+
libicu-dev \
22+
libmemcached-dev \
23+
libxml2-dev \
24+
libpng-dev \
25+
libzip-dev \
26+
libssl-dev \
27+
libgmp-dev \
28+
unzip \
29+
vim \
30+
zip
31+
32+
RUN pecl install imagick; \
33+
pecl install memcached; \
34+
pecl install redis; \
35+
pecl install apcu; \
36+
# https://github.com/php/pecl-encryption-mcrypt/issues/7#issuecomment-1050994596
37+
pecl install -n mcrypt; \
38+
pecl install gmagick-2.0.6RC1; \
39+
pecl install timezonedb; \
40+
docker-php-ext-configure gd --with-freetype --with-jpeg --with-webp; \
41+
docker-php-ext-configure zip; \
42+
docker-php-ext-install gd; \
43+
PHP_OPENSSL=yes docker-php-ext-configure imap --with-kerberos --with-imap-ssl; \
44+
docker-php-ext-install imap; \
45+
docker-php-ext-install mysqli; \
46+
docker-php-ext-install pdo_mysql; \
47+
docker-php-ext-install opcache; \
48+
docker-php-ext-install soap; \
49+
docker-php-ext-install intl; \
50+
docker-php-ext-install zip; \
51+
docker-php-ext-install exif; \
52+
docker-php-ext-install calendar; \
53+
docker-php-ext-install gmp; \
54+
docker-php-ext-install pcntl; \
55+
docker-php-ext-install shmop; \
56+
docker-php-ext-install sockets; \
57+
docker-php-ext-install sysvsem; \
58+
docker-php-ext-install sysvshm; \
59+
docker-php-ext-install bcmath; \
60+
docker-php-ext-enable imagick mcrypt redis timezonedb apcu; \
61+
echo "extension=memcached.so" >> /usr/local/etc/php/conf.d/memcached.ini; \
62+
echo "extension=gmagick.so" >> /usr/local/etc/php/conf.d/gmagick.ini; \
63+
apt-get purge -y --auto-remove -o APT::AutoRemove::RecommendsImportant=false; \
64+
rm -rf /var/lib/apt/lists/*;
65+
66+
# set recommended PHP.ini settings
67+
# see https://secure.php.net/manual/en/opcache.installation.php
68+
RUN { \
69+
echo 'opcache.memory_consumption=128'; \
70+
echo 'opcache.interned_strings_buffer=8'; \
71+
echo 'opcache.max_accelerated_files=4000'; \
72+
echo 'opcache.revalidate_freq=2'; \
73+
echo 'opcache.fast_shutdown=1'; \
74+
echo 'opcache.enable_cli=1'; \
75+
} > /usr/local/etc/php/conf.d/opcache-recommended.ini
76+
77+
# Donwload and install composer
78+
RUN curl -sSL "https://getcomposer.org/installer" | php \
79+
&& mv composer.phar /usr/local/bin/composer
80+
81+
# Install wp-cli
82+
RUN curl -O "https://raw.githubusercontent.com/wp-cli/builds/gh-pages/phar/wp-cli.phar" \
83+
&& chmod +x wp-cli.phar \
84+
&& mv wp-cli.phar /usr/local/bin/wp
85+
86+
# Setup a config file
87+
RUN mkdir -p /etc/wp-cli
88+
RUN { \
89+
echo 'path: /var/www/htdocs'; \
90+
} > /etc/wp-cli/config.yml
91+
92+
RUN mkdir /usr/local/etc/misc && \
93+
touch /usr/local/etc/misc/msmtprc && \
94+
ln -s /usr/local/etc/misc/msmtprc /etc/msmtprc && \
95+
chown www-data:www-data /usr/local/etc/misc/msmtprc && \
96+
chown www-data:www-data /etc/msmtprc
97+
98+
RUN latest_build=$(curl -s https://download.newrelic.com/php_agent/release/ | grep 'linux.tar.gz' | sed 's/.*"\(.*\)".*/\1/') && \
99+
curl -L "https://download.newrelic.com$latest_build" | tar -C /tmp -zx && \
100+
export NR_INSTALL_USE_CP_NOT_LN=1 && \
101+
export NR_INSTALL_SILENT=1 && \
102+
/tmp/newrelic-php5-*/newrelic-install install && \
103+
rm -rf /tmp/newrelic-php5-* /tmp/nrinstall*
104+
105+
ENV NR_PORT=/run/newrelic/newrelic.sock
106+
107+
# Setup logs
108+
RUN mkdir -p /var/log/php; \
109+
chown -R www-data: /var/log/php; \
110+
rm /usr/local/etc/php-fpm.d/*;
111+
COPY php.ini /usr/local/etc/php/php.ini
112+
COPY easyengine.conf /usr/local/etc/php-fpm.d/easyengine.conf
113+
114+
COPY expose_off.ini /usr/local/etc/php/conf.d/expose_off.ini
115+
COPY bashrc /root/.bashrc
116+
COPY bashrc /var/www/.bashrc
117+
COPY docker-entrypoint.sh /usr/local/bin/
118+
COPY newrelic.ini /usr/local/etc/php/conf.d/newrelic.ini
119+
COPY newrelic.ini /data/newrelic.ini
120+
121+
WORKDIR /var/www/htdocs
122+
USER www-data
123+
124+
ENTRYPOINT ["docker-entrypoint.sh"]
125+
CMD ["php-fpm"]

php/8.3/bashrc

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
PS1="\`if [ \$? = 0 ]; then echo \[\e[37m\]^_^[\u@$VIRTUAL_HOST:\w]\\$ \[\e[0m\]; else echo \[\e[31m\]O_O[\u@$VIRTUAL_HOST:\w]\\$ \[\e[0m\]; fi\`"
2+
export HISTTIMEFORMAT="%d/%m/%y %T "

php/8.3/docker-entrypoint.sh

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
#!/bin/bash
2+
set -euo pipefail -o nounset
3+
4+
if [[ -z "${NEWRELIC_LICENSE_KEY:-}" ]] || [[ -z "${NEWRELIC_APPNAME:-}" ]]; then
5+
:
6+
else
7+
sed -i -e "s/\"REPLACE_WITH_REAL_KEY\"/\"$NEWRELIC_LICENSE_KEY\"/" \
8+
-e "s/newrelic.appname = \"PHP Application\"/newrelic.appname = \"$NEWRELIC_APPNAME\"/" \
9+
/usr/local/etc/php/conf.d/newrelic.ini
10+
fi
11+
12+
exec "$@"

php/8.3/easyengine.conf

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
[global]
2+
error_log = /var/log/php/error.log
3+
daemonize = no
4+
5+
[www]
6+
ping.path = /ee-admin/ping
7+
pm.status_path = /ee-admin/status
8+
request_terminate_timeout = 300
9+
user = www-data
10+
group = www-data
11+
pm = ondemand
12+
pm.max_children = 20
13+
listen = 9000
14+
; if we send this to /proc/self/fd/1, it never appears
15+
access.log = /var/log/php/access.log
16+
17+
clear_env = no
18+
19+
; Ensure worker stdout and stderr are sent to the main error log.
20+
catch_workers_output = yes

php/8.3/expose_off.ini

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
expose_php = Off

php/8.3/newrelic.ini

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
; This file contains the various settings for the New Relic PHP agent. There
2+
; are many options, all of which are described in detail at the following URL:
3+
; https://docs.newrelic.com/docs/agents/php-agent/configuration/php-agent-configuration
4+
;
5+
6+
extension = "newrelic.so"
7+
8+
[newrelic]
9+
newrelic.license = "REPLACE_WITH_REAL_KEY"
10+
newrelic.appname = "PHP Application"
11+
newrelic.logfile = "/var/log/newrelic/php_agent.log"
12+
newrelic.daemon.logfile = "/var/log/newrelic/newrelic-daemon.log"
13+
newrelic.daemon.port = "/run/newrelic/newrelic.sock"
14+
newrelic.transaction_tracer.record_sql = "raw"
15+
newrelic.transaction_tracer.threshold = "1s"
16+
newrelic.browser_monitoring.auto_instrument = 0
17+
newrelic.application_logging.forwarding.log_level = error
18+
newrelic.daemon.dont_launch = 3

0 commit comments

Comments
 (0)