Skip to content
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

Fixes for newrelic config updates #158

Merged
merged 1 commit into from
Nov 10, 2023
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
1 change: 1 addition & 0 deletions php/7.4/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -117,6 +117,7 @@ COPY bashrc /root/.bashrc
COPY bashrc /var/www/.bashrc
COPY docker-entrypoint.sh /usr/local/bin/
COPY newrelic.ini /usr/local/etc/php/conf.d/newrelic.ini
COPY newrelic.ini /data/newrelic.ini

WORKDIR /var/www/htdocs
USER www-data
Expand Down
1 change: 1 addition & 0 deletions php/7.4/docker-entrypoint.sh
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ set -euo pipefail -o nounset
if [[ -z "${NEWRELIC_LICENSE_KEY:-}" ]] || [[ -z "${NEWRELIC_APPNAME:-}" ]]; then
:
else
cp /data/newrelic.ini /usr/local/etc/php/conf.d/newrelic.ini
sed -i -e "s/\"REPLACE_WITH_REAL_KEY\"/\"$NEWRELIC_LICENSE_KEY\"/" \
-e "s/newrelic.appname = \"PHP Application\"/newrelic.appname = \"$NEWRELIC_APPNAME\"/" \
/usr/local/etc/php/conf.d/newrelic.ini
Expand Down
1 change: 1 addition & 0 deletions php/8.0/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -117,6 +117,7 @@ COPY bashrc /root/.bashrc
COPY bashrc /var/www/.bashrc
COPY docker-entrypoint.sh /usr/local/bin/
COPY newrelic.ini /usr/local/etc/php/conf.d/newrelic.ini
COPY newrelic.ini /data/newrelic.ini

WORKDIR /var/www/htdocs
USER www-data
Expand Down
1 change: 1 addition & 0 deletions php/8.0/docker-entrypoint.sh
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ set -euo pipefail -o nounset
if [[ -z "${NEWRELIC_LICENSE_KEY:-}" ]] || [[ -z "${NEWRELIC_APPNAME:-}" ]]; then
:
else
cp /data/newrelic.ini /usr/local/etc/php/conf.d/newrelic.ini
sed -i -e "s/\"REPLACE_WITH_REAL_KEY\"/\"$NEWRELIC_LICENSE_KEY\"/" \
-e "s/newrelic.appname = \"PHP Application\"/newrelic.appname = \"$NEWRELIC_APPNAME\"/" \
/usr/local/etc/php/conf.d/newrelic.ini
Expand Down
1 change: 1 addition & 0 deletions php/8.1/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -117,6 +117,7 @@ COPY bashrc /root/.bashrc
COPY bashrc /var/www/.bashrc
COPY docker-entrypoint.sh /usr/local/bin/
COPY newrelic.ini /usr/local/etc/php/conf.d/newrelic.ini
COPY newrelic.ini /data/newrelic.ini

WORKDIR /var/www/htdocs
USER www-data
Expand Down
1 change: 1 addition & 0 deletions php/8.1/docker-entrypoint.sh
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ set -euo pipefail -o nounset
if [[ -z "${NEWRELIC_LICENSE_KEY:-}" ]] || [[ -z "${NEWRELIC_APPNAME:-}" ]]; then
:
else
cp /data/newrelic.ini /usr/local/etc/php/conf.d/newrelic.ini
sed -i -e "s/\"REPLACE_WITH_REAL_KEY\"/\"$NEWRELIC_LICENSE_KEY\"/" \
-e "s/newrelic.appname = \"PHP Application\"/newrelic.appname = \"$NEWRELIC_APPNAME\"/" \
/usr/local/etc/php/conf.d/newrelic.ini
Expand Down
1 change: 1 addition & 0 deletions php/stable/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -117,6 +117,7 @@ COPY bashrc /root/.bashrc
COPY bashrc /var/www/.bashrc
COPY docker-entrypoint.sh /usr/local/bin/
COPY newrelic.ini /usr/local/etc/php/conf.d/newrelic.ini
COPY newrelic.ini /data/newrelic.ini

WORKDIR /var/www/htdocs
USER www-data
Expand Down
1 change: 1 addition & 0 deletions php/stable/docker-entrypoint.sh
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ set -euo pipefail -o nounset
if [[ -z "${NEWRELIC_LICENSE_KEY:-}" ]] || [[ -z "${NEWRELIC_APPNAME:-}" ]]; then
:
else
cp /data/newrelic.ini /usr/local/etc/php/conf.d/newrelic.ini
sed -i -e "s/\"REPLACE_WITH_REAL_KEY\"/\"$NEWRELIC_LICENSE_KEY\"/" \
-e "s/newrelic.appname = \"PHP Application\"/newrelic.appname = \"$NEWRELIC_APPNAME\"/" \
/usr/local/etc/php/conf.d/newrelic.ini
Expand Down
8 changes: 7 additions & 1 deletion php/stable/newrelic.ini
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
; This file contains the various settings for the New Relic PHP agent. There
; are many options, all of which are described in detail at the following URL:
; https://docs.newrelic.com/docs/agents/php-agent/configuration/php-agent-configuration
;
; Additional options added from https://github.com/newrelic/newrelic-php-agent/issues/577#issue-1435830462

extension = "newrelic.so"

Expand All @@ -16,3 +16,9 @@ newrelic.transaction_tracer.threshold = "1s"
newrelic.browser_monitoring.auto_instrument = 0
newrelic.application_logging.forwarding.log_level = error
newrelic.daemon.dont_launch = 3
newrelic.cross_application_tracer.enabled = false
newrelic.distributed_tracing_enabled = false
newrelic.span_events_enabled = false
newrelic.application_logging.enabled = false
newrelic.application_logging.forwarding.enabled = false
newrelic.application_logging.metrics.enabled = false
Loading