You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@trafficserver.apache.org by bn...@apache.org on 2024/02/09 16:26:20 UTC

(trafficserver-ci) branch main updated: Install Open Telemetry for the otel_tracer plugin (#317)

This is an automated email from the ASF dual-hosted git repository.

bneradt pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/trafficserver-ci.git


The following commit(s) were added to refs/heads/main by this push:
     new efcf796  Install Open Telemetry for the otel_tracer plugin (#317)
efcf796 is described below

commit efcf7961e2995a47f3f1b5802d6476566a1c943e
Author: Brian Neradt <br...@gmail.com>
AuthorDate: Fri Feb 9 10:26:09 2024 -0600

    Install Open Telemetry for the otel_tracer plugin (#317)
---
 docker/fedora39/Dockerfile | 30 +++++++++++++++++++++++++++++-
 1 file changed, 29 insertions(+), 1 deletion(-)

diff --git a/docker/fedora39/Dockerfile b/docker/fedora39/Dockerfile
index 8b6af85..bfa4d79 100644
--- a/docker/fedora39/Dockerfile
+++ b/docker/fedora39/Dockerfile
@@ -30,7 +30,7 @@ RUN <<EOF
     xz-devel libcurl-devel ncurses-devel jemalloc-devel GeoIP-devel luajit-devel brotli-devel \
     ImageMagick-devel ImageMagick-c++-devel hiredis-devel zlib-devel libmaxminddb-devel \
     perl-ExtUtils-MakeMaker perl-Digest-SHA perl-URI perl-IPC-Cmd perl-Pod-Html \
-    curl tcl-devel java cjose-devel
+    curl tcl-devel java cjose-devel protobuf-devel
 
   # autest stuff
   dnf -y install \
@@ -136,6 +136,34 @@ RUN <<EOF
   rm -rf NuRaft
 EOF
 
+# For Open Telemetry Tracer plugin.
+RUN <<EOF
+  set -e
+
+  cd /root
+  mkdir nlohmann-json
+  cd nlohmann-json
+  wget https://github.com/nlohmann/json/archive/refs/tags/v3.11.3.tar.gz
+  tar zxf v3.11.3.tar.gz
+  cd json-3.11.3
+  cmake -B build -G Ninja -DCMAKE_CXX_STANDARD=17 -DCMAKE_CXX_STANDARD_REQUIRED=ON -DCMAKE_INSTALL_PREFIX=/opt -DJSON_BuildTests=OFF
+  cmake --build build
+  cmake --install build
+  cd /root
+  rm -rf nlohmann-json
+
+  mkdir opentelemetry-cpp
+  cd opentelemetry-cpp
+  wget https://github.com/open-telemetry/opentelemetry-cpp/archive/refs/tags/v1.3.0.tar.gz
+  tar zxf v1.3.0.tar.gz
+  cd opentelemetry-cpp-1.3.0
+  cmake -B build -G Ninja -DBUILD_TESTING=OFF -DWITH_EXAMPLES=OFF -DWITH_JAEGER=OFF -DWITH_OTLP=ON -DWITH_OTLP_GRPC=OFF -DWITH_OTLP_HTTP=ON -DCMAKE_POSITION_INDEPENDENT_CODE=ON -DCMAKE_CXX_STANDARD=17 -DCMAKE_CXX_STANDARD_REQUIRED=ON -Dnlohmann_json_ROOT=/opt/ -DCMAKE_INSTALL_PREFIX=/opt
+  cmake --build build --target all
+  cmake --install build --config Debug
+  cd /root
+  rm -rf opentelemetry-cpp
+EOF
+
 # Add the CI's test user. N.B: 1200 is the uid that our jenkins user is
 # configured with, so that has to be used. Otherwise there will be permissions
 # issues.