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

Apache instrumentation v1.0 #1236

Merged
merged 7 commits into from
Nov 26, 2022
Merged
Show file tree
Hide file tree
Changes from 2 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
26 changes: 26 additions & 0 deletions autoinstrumentation/apache/Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@

############################
# STEP 1 download the webserver agent
############################
FROM alpine:latest as agent

ARG version

RUN mkdir /opt/opentelemetry
WORKDIR /opt/opentelemetry

RUN wget https://github.com/open-telemetry/opentelemetry-cpp-contrib/releases/download/webserver%2Fv$version/opentelemetry-webserver-sdk-x64-linux.tgz.zip
RUN unzip opentelemetry-webserver-sdk-x64-linux.tgz.zip
RUN mkdir agent
RUN tar -xvf opentelemetry-webserver-sdk-x64-linux.tgz -C agent

############################
# STEP 2 download the webserver agent
############################
FROM alpine:latest

COPY --from=agent /opt/opentelemetry/agent/opentelemetry-webserver-sdk /opt/opentelemetry

RUN chmod a+w /opt/opentelemetry/logs

CMD ["cat", "Just delivering the Opentelemetry Apache/Nginx agent"]
13 changes: 13 additions & 0 deletions autoinstrumentation/apache/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
# How to build Apache auto-instrumentation docker image
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

can we come up with a more explicit name (for the directory/image/readme name)? Apache is just too generic


To build image for Apache auto instrumentation, use the following commands

```
export REPO_NAME="<your-docker-image-repo-name>"
export IMAGE_NAME_PREFIX="opentelemetry-apache-agent"
export IMAGE_VERSION=`cat version.txt`
export IMAGE_NAME=${REPO_NAME}/${IMAGE_NAME_PREFIX}:${IMAGE_VERSION}
docker build --build-arg version=${IMAGE_VERSION} . -t ${IMAGE_NAME} -t ${REPO_NAME}/${IMAGE_NAME_PREFIX}:latest
docker push ${IMAGE_NAME}
docker push ${REPO_NAME}/${IMAGE_NAME_PREFIX}:latest
```
1 change: 1 addition & 0 deletions autoinstrumentation/apache/version.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
1.0.2