Skip to content

Commit

Permalink
Merge branch 'main' into deprecate/php80images
Browse files Browse the repository at this point in the history
  • Loading branch information
tobybellwood committed Jan 23, 2024
2 parents 74648a0 + 3ad992c commit e86d79d
Show file tree
Hide file tree
Showing 8 changed files with 54 additions and 54 deletions.
10 changes: 5 additions & 5 deletions helpers/TESTING_base_images_dockercompose.md
Original file line number Diff line number Diff line change
Expand Up @@ -168,11 +168,11 @@ docker-compose exec -T php-8-3-dev bash -c "php -i" | grep "sendmail_path" | gre
docker-compose exec -T commons sh -c "curl -kL http://php-8-3-dev:9000" | grep "xdebug.client_port" | grep "9003"
docker-compose exec -T commons sh -c "curl -kL http://php-8-3-dev:9000" | grep "PHP_IDE_CONFIG" | grep "serverName=lagoon"
docker-compose exec -T commons sh -c "curl -kL http://php-8-3-dev:9000" | grep "xdebug.log" | grep "/tmp/xdebug.log"
# TODO docker-compose exec -T commons sh -c "curl -kL http://php-8-3-dev:9000" | grep "newrelic.appname" | grep "noproject-nobranch"
# TODO docker-compose exec -T commons sh -c "curl -kL http://php-8-3-dev:9000" | grep "newrelic.application_logging.enabled" | grep "disabled"
# TODO docker-compose exec -T commons sh -c "curl -kL http://php-8-3-dev:9000" | grep "newrelic.logfile" | grep "/dev/stderr"
# TODO docker-compose exec -T commons sh -c "curl -kL http://php-8-3-dev:9000" | grep "Blackfire" | grep "enabled"
# TODO docker-compose exec -T commons sh -c "curl -kL http://php-8-3-dev:9000" | grep "blackfire.agent_socket" | grep "tcp://127.0.0.1:8307"
docker-compose exec -T commons sh -c "curl -kL http://php-8-3-dev:9000" | grep "newrelic.appname" | grep "noproject-nobranch"
docker-compose exec -T commons sh -c "curl -kL http://php-8-3-dev:9000" | grep "newrelic.application_logging.enabled" | grep "disabled"
docker-compose exec -T commons sh -c "curl -kL http://php-8-3-dev:9000" | grep "newrelic.logfile" | grep "/dev/stderr"
docker-compose exec -T commons sh -c "curl -kL http://php-8-3-dev:9000" | grep "Blackfire" | grep "enabled"
docker-compose exec -T commons sh -c "curl -kL http://php-8-3-dev:9000" | grep "blackfire.agent_socket" | grep "tcp://127.0.0.1:8307"

# PHP 8.3 production should have overridden configuration.
docker-compose exec -T commons sh -c "curl -kL http://php-8-3-prod:9000" | grep "max_input_vars" | grep "4000"
Expand Down
4 changes: 2 additions & 2 deletions helpers/images-docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -106,8 +106,8 @@ services:
- LAGOON_ENVIRONMENT_TYPE=development
- XDEBUG_ENABLE=true
- XDEBUG_LOG=true
# TODO - NEWRELIC_ENABLED=true
# TODO - BLACKFIRE_ENABLED=true
- NEWRELIC_ENABLED=true
- BLACKFIRE_ENABLED=true
- NEWRELIC_APPLICATION_LOGGING_ENABLED=false
<< : *default-user # uses the defined user from top
command: ["sh", "-c", "
Expand Down
2 changes: 1 addition & 1 deletion images/nginx/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
ARG IMAGE_REPO
FROM ${IMAGE_REPO:-lagoon}/commons as commons
FROM openresty/openresty:1.21.4.3-2-alpine
FROM openresty/openresty:1.21.4.3-3-alpine

LABEL org.opencontainers.image.authors="The Lagoon Authors" maintainer="The Lagoon Authors"
LABEL org.opencontainers.image.source="https://github.com/uselagoon/lagoon-images" repository="https://github.com/uselagoon/lagoon-images"
Expand Down
2 changes: 1 addition & 1 deletion images/node/20.Dockerfile
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
ARG IMAGE_REPO
FROM ${IMAGE_REPO:-lagoon}/commons as commons
FROM node:20.10-alpine3.18
FROM node:20.11-alpine3.18

LABEL org.opencontainers.image.authors="The Lagoon Authors" maintainer="The Lagoon Authors"
LABEL org.opencontainers.image.source="https://github.com/uselagoon/lagoon-images" repository="https://github.com/uselagoon/lagoon-images"
Expand Down
6 changes: 3 additions & 3 deletions images/php-fpm/8.1.Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ FROM composer:latest as healthcheckbuilder

RUN composer create-project --no-dev amazeeio/healthz-php /healthz-php v0.0.6

FROM php:8.1.26-fpm-alpine3.18
FROM php:8.1.27-fpm-alpine3.18

LABEL org.opencontainers.image.authors="The Lagoon Authors" maintainer="The Lagoon Authors"
LABEL org.opencontainers.image.source="https://github.com/uselagoon/lagoon-images" repository="https://github.com/uselagoon/lagoon-images"
Expand Down Expand Up @@ -111,7 +111,7 @@ RUN apk update \
# New Relic PHP Agent.
# @see https://docs.newrelic.com/docs/release-notes/agent-release-notes/php-release-notes/
# @see https://docs.newrelic.com/docs/agents/php-agent/getting-started/php-agent-compatibility-requirements
ENV NEWRELIC_VERSION=10.14.0.3
ENV NEWRELIC_VERSION=10.15.0.4
RUN mkdir -p /tmp/newrelic && cd /tmp/newrelic \
&& wget https://download.newrelic.com/php_agent/archive/${NEWRELIC_VERSION}/newrelic-php5-${NEWRELIC_VERSION}-linux-musl.tar.gz \
&& gzip -dc newrelic-php5-${NEWRELIC_VERSION}-linux-musl.tar.gz | tar --strip-components=1 -xf - \
Expand All @@ -133,7 +133,7 @@ RUN mkdir -p /tmp/newrelic && cd /tmp/newrelic \
&& fix-permissions /usr/local/etc/

# Add blackfire probe and agent.
ENV BLACKFIRE_VERSION=2.23.0
ENV BLACKFIRE_VERSION=2.24.4
RUN version=$(php -r "echo PHP_MAJOR_VERSION.PHP_MINOR_VERSION;") \
&& architecture=$(case $(uname -m) in x86_64 | amd64) echo "amd64" ;; aarch64 | arm64 | armv8) echo "arm64" ;; *) echo "amd64" ;; esac) \
&& mkdir -p /blackfire \
Expand Down
6 changes: 3 additions & 3 deletions images/php-fpm/8.2.Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ FROM composer:latest as healthcheckbuilder

RUN composer create-project --no-dev amazeeio/healthz-php /healthz-php v0.0.6

FROM php:8.2.13-fpm-alpine3.18
FROM php:8.2.15-fpm-alpine3.18

LABEL org.opencontainers.image.authors="The Lagoon Authors" maintainer="The Lagoon Authors"
LABEL org.opencontainers.image.source="https://github.com/uselagoon/lagoon-images" repository="https://github.com/uselagoon/lagoon-images"
Expand Down Expand Up @@ -111,7 +111,7 @@ RUN apk update \
# New Relic PHP Agent.
# @see https://docs.newrelic.com/docs/release-notes/agent-release-notes/php-release-notes/
# @see https://docs.newrelic.com/docs/agents/php-agent/getting-started/php-agent-compatibility-requirements
ENV NEWRELIC_VERSION=10.14.0.3
ENV NEWRELIC_VERSION=10.15.0.4
RUN mkdir -p /tmp/newrelic && cd /tmp/newrelic \
&& wget https://download.newrelic.com/php_agent/archive/${NEWRELIC_VERSION}/newrelic-php5-${NEWRELIC_VERSION}-linux-musl.tar.gz \
&& gzip -dc newrelic-php5-${NEWRELIC_VERSION}-linux-musl.tar.gz | tar --strip-components=1 -xf - \
Expand All @@ -133,7 +133,7 @@ RUN mkdir -p /tmp/newrelic && cd /tmp/newrelic \
&& fix-permissions /usr/local/etc/

# Add blackfire probe and agent.
ENV BLACKFIRE_VERSION=2.23.0
ENV BLACKFIRE_VERSION=2.24.4
RUN version=$(php -r "echo PHP_MAJOR_VERSION.PHP_MINOR_VERSION;") \
&& architecture=$(case $(uname -m) in x86_64 | amd64) echo "amd64" ;; aarch64 | arm64 | armv8) echo "arm64" ;; *) echo "amd64" ;; esac) \
&& mkdir -p /blackfire \
Expand Down
76 changes: 38 additions & 38 deletions images/php-fpm/8.3.Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ FROM composer:latest as healthcheckbuilder

RUN composer create-project --no-dev amazeeio/healthz-php /healthz-php v0.0.6

FROM php:8.3.0-fpm-alpine3.18
FROM php:8.3.2-fpm-alpine3.18

LABEL org.opencontainers.image.authors="The Lagoon Authors" maintainer="The Lagoon Authors"
LABEL org.opencontainers.image.source="https://github.com/uselagoon/lagoon-images" repository="https://github.com/uselagoon/lagoon-images"
Expand Down Expand Up @@ -120,45 +120,45 @@ RUN apk update \
# New Relic PHP Agent.
# @see https://docs.newrelic.com/docs/release-notes/agent-release-notes/php-release-notes/
# @see https://docs.newrelic.com/docs/agents/php-agent/getting-started/php-agent-compatibility-requirements
ENV NEWRELIC_VERSION=10.14.0.3
# TODO RUN mkdir -p /tmp/newrelic && cd /tmp/newrelic \
# && wget https://download.newrelic.com/php_agent/archive/${NEWRELIC_VERSION}/newrelic-php5-${NEWRELIC_VERSION}-linux-musl.tar.gz \
# && gzip -dc newrelic-php5-${NEWRELIC_VERSION}-linux-musl.tar.gz | tar --strip-components=1 -xf - \
# && NR_INSTALL_USE_CP_NOT_LN=1 NR_INSTALL_SILENT=1 ./newrelic-install install \
# && sed -i -e "s/newrelic.appname = .*/newrelic.appname = \"\${LAGOON_PROJECT:-noproject}-\${LAGOON_GIT_SAFE_BRANCH:-nobranch}\"/" /usr/local/etc/php/conf.d/newrelic.ini \
# && sed -i -e "s/;newrelic.enabled = .*/newrelic.enabled = \${NEWRELIC_ENABLED:-false}/" /usr/local/etc/php/conf.d/newrelic.ini \
# && sed -i -e "s/;newrelic.browser_monitoring.auto_instrument = .*/newrelic.browser_monitoring.auto_instrument = \${NEWRELIC_BROWSER_MONITORING_ENABLED:-true}/" /usr/local/etc/php/conf.d/newrelic.ini \
# && sed -i -e "s/;newrelic.distributed_tracing_enabled = .*/newrelic.distributed_tracing_enabled = \${NEWRELIC_DISTRIBUTED_TRACING_ENABLED:-false}/" /usr/local/etc/php/conf.d/newrelic.ini \
# && sed -i -e "s/newrelic.license = .*/newrelic.license = \"\${NEWRELIC_LICENSE:-}\"/" /usr/local/etc/php/conf.d/newrelic.ini \
# && sed -i -e "s/;newrelic.loglevel = .*/newrelic.loglevel = \"\${NEWRELIC_LOG_LEVEL:-warning}\"/" /usr/local/etc/php/conf.d/newrelic.ini \
# && sed -i -e "s/;newrelic.daemon.loglevel = .*/newrelic.daemon.loglevel = \"\${NEWRELIC_DAEMON_LOG_LEVEL:-warning}\"/" /usr/local/etc/php/conf.d/newrelic.ini \
# && sed -i -e "s/newrelic.logfile = .*/newrelic.logfile = \"\/dev\/stderr\"/" /usr/local/etc/php/conf.d/newrelic.ini \
# && sed -i -e "s/newrelic.daemon.logfile = .*/newrelic.daemon.logfile = \"\/dev\/stderr\"/" /usr/local/etc/php/conf.d/newrelic.ini \
# && sed -i -e "s/;newrelic.application_logging.enabled = .*/newrelic.application_logging.enabled = \${NEWRELIC_APPLICATION_LOGGING_ENABLED:-true}/" /usr/local/etc/php/conf.d/newrelic.ini \
# && sed -i -e "s/;newrelic.application_logging.metrics.enabled = .*/newrelic.application_logging.metrics.enabled = \${NEWRELIC_APPLICATION_LOGGING_METRICS_ENABLED:-true}/" /usr/local/etc/php/conf.d/newrelic.ini \
# && sed -i -e "s/;newrelic.application_logging.forwarding.enabled = .*/newrelic.application_logging.forwarding.enabled = \${NEWRELIC_APPLICATION_LOGGING_FORWARDING_ENABLED:-true}/" /usr/local/etc/php/conf.d/newrelic.ini \
# && mv /usr/local/etc/php/conf.d/newrelic.ini /usr/local/etc/php/conf.d/newrelic.disable \
# && cd / && rm -rf /tmp/newrelic \
# && fix-permissions /usr/local/etc/
ENV NEWRELIC_VERSION=10.15.0.4
RUN mkdir -p /tmp/newrelic && cd /tmp/newrelic \
&& wget https://download.newrelic.com/php_agent/archive/${NEWRELIC_VERSION}/newrelic-php5-${NEWRELIC_VERSION}-linux-musl.tar.gz \
&& gzip -dc newrelic-php5-${NEWRELIC_VERSION}-linux-musl.tar.gz | tar --strip-components=1 -xf - \
&& NR_INSTALL_USE_CP_NOT_LN=1 NR_INSTALL_SILENT=1 ./newrelic-install install \
&& sed -i -e "s/newrelic.appname = .*/newrelic.appname = \"\${LAGOON_PROJECT:-noproject}-\${LAGOON_GIT_SAFE_BRANCH:-nobranch}\"/" /usr/local/etc/php/conf.d/newrelic.ini \
&& sed -i -e "s/;newrelic.enabled = .*/newrelic.enabled = \${NEWRELIC_ENABLED:-false}/" /usr/local/etc/php/conf.d/newrelic.ini \
&& sed -i -e "s/;newrelic.browser_monitoring.auto_instrument = .*/newrelic.browser_monitoring.auto_instrument = \${NEWRELIC_BROWSER_MONITORING_ENABLED:-true}/" /usr/local/etc/php/conf.d/newrelic.ini \
&& sed -i -e "s/;newrelic.distributed_tracing_enabled = .*/newrelic.distributed_tracing_enabled = \${NEWRELIC_DISTRIBUTED_TRACING_ENABLED:-false}/" /usr/local/etc/php/conf.d/newrelic.ini \
&& sed -i -e "s/newrelic.license = .*/newrelic.license = \"\${NEWRELIC_LICENSE:-}\"/" /usr/local/etc/php/conf.d/newrelic.ini \
&& sed -i -e "s/;newrelic.loglevel = .*/newrelic.loglevel = \"\${NEWRELIC_LOG_LEVEL:-warning}\"/" /usr/local/etc/php/conf.d/newrelic.ini \
&& sed -i -e "s/;newrelic.daemon.loglevel = .*/newrelic.daemon.loglevel = \"\${NEWRELIC_DAEMON_LOG_LEVEL:-warning}\"/" /usr/local/etc/php/conf.d/newrelic.ini \
&& sed -i -e "s/newrelic.logfile = .*/newrelic.logfile = \"\/dev\/stderr\"/" /usr/local/etc/php/conf.d/newrelic.ini \
&& sed -i -e "s/newrelic.daemon.logfile = .*/newrelic.daemon.logfile = \"\/dev\/stderr\"/" /usr/local/etc/php/conf.d/newrelic.ini \
&& sed -i -e "s/;newrelic.application_logging.enabled = .*/newrelic.application_logging.enabled = \${NEWRELIC_APPLICATION_LOGGING_ENABLED:-true}/" /usr/local/etc/php/conf.d/newrelic.ini \
&& sed -i -e "s/;newrelic.application_logging.metrics.enabled = .*/newrelic.application_logging.metrics.enabled = \${NEWRELIC_APPLICATION_LOGGING_METRICS_ENABLED:-true}/" /usr/local/etc/php/conf.d/newrelic.ini \
&& sed -i -e "s/;newrelic.application_logging.forwarding.enabled = .*/newrelic.application_logging.forwarding.enabled = \${NEWRELIC_APPLICATION_LOGGING_FORWARDING_ENABLED:-true}/" /usr/local/etc/php/conf.d/newrelic.ini \
&& mv /usr/local/etc/php/conf.d/newrelic.ini /usr/local/etc/php/conf.d/newrelic.disable \
&& cd / && rm -rf /tmp/newrelic \
&& fix-permissions /usr/local/etc/

# Add blackfire probe and agent.
ENV BLACKFIRE_VERSION=2.23.0
# TODO version=$(php -r "echo PHP_MAJOR_VERSION.PHP_MINOR_VERSION;") \
# && architecture=$(case $(uname -m) in x86_64 | amd64) echo "amd64" ;; aarch64 | arm64 | armv8) echo "arm64" ;; *) echo "amd64" ;; esac) \
# && mkdir -p /blackfire \
# && curl -A "Docker" -o /blackfire/blackfire-probe.tar.gz -D - -L -s https://blackfire.io/api/v1/releases/probe/php/alpine/$architecture/$version \
# && tar zxpf /blackfire/blackfire-probe.tar.gz -C /blackfire \
# && mv /blackfire/blackfire-*.so $(php -r "echo ini_get('extension_dir');")/blackfire.so \
# && fix-permissions /usr/local/etc/php/conf.d/

# TODO RUN architecture=$(case $(uname -m) in x86_64 | amd64) echo "amd64" ;; aarch64 | arm64 | armv8) echo "arm64" ;; *) echo "amd64" ;; esac) \
# && curl -A "Docker" -o /blackfire/blackfire-linux_${architecture}.tar.gz -D - -L -s https://packages.blackfire.io/binaries/blackfire/${BLACKFIRE_VERSION}/blackfire-linux_${architecture}.tar.gz \
# && tar zxpf /blackfire/blackfire-linux_${architecture}.tar.gz -C /blackfire \
# && mv /blackfire/blackfire /bin/blackfire \
# && chmod +x /bin/blackfire \
# && mkdir -p /etc/blackfire \
# && touch /etc/blackfire/agent \
# && fix-permissions /etc/blackfire/
ENV BLACKFIRE_VERSION=2.24.4
RUN version=$(php -r "echo PHP_MAJOR_VERSION.PHP_MINOR_VERSION;") \
&& architecture=$(case $(uname -m) in x86_64 | amd64) echo "amd64" ;; aarch64 | arm64 | armv8) echo "arm64" ;; *) echo "amd64" ;; esac) \
&& mkdir -p /blackfire \
&& curl -A "Docker" -o /blackfire/blackfire-probe.tar.gz -D - -L -s https://blackfire.io/api/v1/releases/probe/php/alpine/$architecture/$version \
&& tar zxpf /blackfire/blackfire-probe.tar.gz -C /blackfire \
&& mv /blackfire/blackfire-*.so $(php -r "echo ini_get('extension_dir');")/blackfire.so \
&& fix-permissions /usr/local/etc/php/conf.d/

RUN architecture=$(case $(uname -m) in x86_64 | amd64) echo "amd64" ;; aarch64 | arm64 | armv8) echo "arm64" ;; *) echo "amd64" ;; esac) \
&& curl -A "Docker" -o /blackfire/blackfire-linux_${architecture}.tar.gz -D - -L -s https://packages.blackfire.io/binaries/blackfire/${BLACKFIRE_VERSION}/blackfire-linux_${architecture}.tar.gz \
&& tar zxpf /blackfire/blackfire-linux_${architecture}.tar.gz -C /blackfire \
&& mv /blackfire/blackfire /bin/blackfire \
&& chmod +x /bin/blackfire \
&& mkdir -p /etc/blackfire \
&& touch /etc/blackfire/agent \
&& fix-permissions /etc/blackfire/

RUN mkdir -p /app \
&& fix-permissions /app \
Expand Down
2 changes: 1 addition & 1 deletion images/ruby/3.2.Dockerfile
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
ARG IMAGE_REPO
FROM ${IMAGE_REPO:-lagoon}/commons as commons

FROM ruby:3.2.2-alpine3.18
FROM ruby:3.2.3-alpine3.18

LABEL org.opencontainers.image.authors="The Lagoon Authors" maintainer="The Lagoon Authors"
LABEL org.opencontainers.image.source="https://github.com/uselagoon/lagoon-images" repository="https://github.com/uselagoon/lagoon-images"
Expand Down

0 comments on commit e86d79d

Please sign in to comment.