-
Notifications
You must be signed in to change notification settings - Fork 2.4k
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
Add Official Newrelic PHP Daemon Image #6843
Conversation
I'm guessing this is the image we were hypothetically discussing over in docker-library/faq#9? 😅 |
Yes, it sure is. |
So, I think what's discussed there is definitely still relevant here -- while I'm sure this image is useful in combination with New Relic, it's not exactly "generally useful" right? For example, if someone isn't using the New Relic SaaS product, they wouldn't get any value from this image? |
That is correct. I'm not sure what you mean by "generally useful." Is your concern with the cost? We do offer a trial period, and once that ends, the account becomes a free lite account, similar to zend server, but with a free version available. Is your concern because the image is vendor-specific? I imagine this image to be similar to the database images but for monitoring. It should be pretty plug and play, the daemon is mostly a proxy. If you're using a |
My reasoning for my reaction is that this image is tied to a single specific SAAS offering. It is not a generic service that you would plug into another system. All the other images here are a self-contained service, language stack, or base OS; they don't require a hosted service to use. |
Diff for 501ea10:failed fetching repo "newrelic-php-daemon"
unable to find a manifest named "newrelic-php-daemon" (in "/tmp/tmp.tUB8w2q7E9/oi/library" or as a remote URL)
diff --git a/_bashbrew-arches b/_bashbrew-arches
index e69de29..8540e4b 100644
--- a/_bashbrew-arches
+++ b/_bashbrew-arches
@@ -0,0 +1 @@
+newrelic-php-daemon:9.2 @ amd64
diff --git a/_bashbrew-list b/_bashbrew-list
index e69de29..463d92a 100644
--- a/_bashbrew-list
+++ b/_bashbrew-list
@@ -0,0 +1,4 @@
+newrelic-php-daemon:9.2
+newrelic-php-daemon:9.2.0
+newrelic-php-daemon:9.2.0.247
+newrelic-php-daemon:latest
diff --git a/_bashbrew.err b/_bashbrew.err
index 8e6eb5e..e69de29 100644
--- a/_bashbrew.err
+++ b/_bashbrew.err
@@ -1,6 +0,0 @@
-failed fetching repo "newrelic-php-daemon"
-unable to find a manifest named "newrelic-php-daemon" (in "/tmp/tmp.tUB8w2q7E9/oi/library" or as a remote URL)
-failed fetching repo "newrelic-php-daemon"
-unable to find a manifest named "newrelic-php-daemon" (in "/tmp/tmp.tUB8w2q7E9/oi/library" or as a remote URL)
-failed fetching repo "newrelic-php-daemon"
-unable to find a manifest named "newrelic-php-daemon" (in "/tmp/tmp.tUB8w2q7E9/oi/library" or as a remote URL)
diff --git a/newrelic-php-daemon_9.2/Dockerfile b/newrelic-php-daemon_9.2/Dockerfile
new file mode 100644
index 0000000..57e9499
--- /dev/null
+++ b/newrelic-php-daemon_9.2/Dockerfile
@@ -0,0 +1,37 @@
+#------------------------------------------------------------------------------
+# Copyright [2019] New Relic Corporation. All rights reserved.
+# SPDX-License-Identifier: Apache-2.0
+#------------------------------------------------------------------------------
+
+
+FROM alpine:3.10 AS build
+
+ENV NEWRELIC_VERSION 9.2.0.247
+ENV NEWRELIC_NAME newrelic-php5-${NEWRELIC_VERSION}-linux-musl
+ENV NEWRELIC_SHA d0b3cccf3a26ba0c266ae95aaea48a98283b1500b183cecd9218315f98e59c7d
+
+RUN set -ex; \
+ wget -O /tmp/${NEWRELIC_NAME}.tar.gz https://download.newrelic.com/php_agent/archive/${NEWRELIC_VERSION}/${NEWRELIC_NAME}.tar.gz; \
+ cd /tmp/; \
+ echo "$NEWRELIC_SHA $NEWRELIC_NAME.tar.gz" | sha256sum -c; \
+ tar -xzf ${NEWRELIC_NAME}.tar.gz; \
+ export NR_INSTALL_SILENT=1; \
+ ${NEWRELIC_NAME}/newrelic-install install_daemon
+
+FROM alpine:3.10
+
+# The daemon needs certs installed to run
+RUN apk add --no-cache \
+ ca-certificates
+
+RUN set -ex; \
+ mkdir /var/log/newrelic
+
+COPY docker-entrypoint.sh /usr/bin/docker-entrypoint.sh
+COPY --from=build /usr/bin/newrelic-daemon /usr/bin/newrelic-daemon
+
+EXPOSE 31339
+
+ENTRYPOINT ["sh","/usr/bin/docker-entrypoint.sh"]
+
+CMD ["/usr/bin/newrelic-daemon"]
diff --git a/newrelic-php-daemon_9.2/docker-entrypoint.sh b/newrelic-php-daemon_9.2/docker-entrypoint.sh
new file mode 100644
index 0000000..d95b125
--- /dev/null
+++ b/newrelic-php-daemon_9.2/docker-entrypoint.sh
@@ -0,0 +1,15 @@
+#!/bin/sh
+#------------------------------------------------------------------------------
+# Copyright [2019] New Relic Corporation. All rights reserved.
+# SPDX-License-Identifier: Apache-2.0
+#------------------------------------------------------------------------------
+set -e
+
+# this if will check if the first argument is a flag
+if [ "${1:0:1}" = '-' ]; then
+ set -- /usr/bin/newrelic-daemon --logfile /proc/self/fd/1 --watchdog-foreground --address="$(hostname)":31339 "$@"
+elif [ "$1" = '/usr/bin/newrelic-daemon' ]; then
+ set -- "$@" --logfile /proc/self/fd/1 --watchdog-foreground --address="$(hostname)":31339
+fi
+
+exec "$@" |
Closing given my comment just above: #6843 (comment). |
Hello,
We, the New Relic PHP Agent team, would like to add an official image for our New Relic PHP Agent daemon.
foobar
needs Node.js, hasFROM node:...
instead of grabbingnode
via other means been considered?)FROM scratch
, tarballs only exist in a single commit within the associated history?