Skip to content

Commit

Permalink
feat: add opentelemetry-collector image to pass certification (#101)
Browse files Browse the repository at this point in the history
Signed-off-by: Dominik Rosiek <[email protected]>
  • Loading branch information
sumo-drosiek authored Jun 26, 2024
1 parent 87f0c4b commit 8244d91
Show file tree
Hide file tree
Showing 2 changed files with 35 additions and 0 deletions.
30 changes: 30 additions & 0 deletions opentelemetry-collector/Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
ARG UPSTREAM_VERSION

## Use original image to copy files from
## ref: https://github.com/SumoLogic/opentelemetry-collector-contrib/blob/5fd8754cbf0b9d88309cba2c9fee4a5342f3ed95/cmd/otelcontribcol/Dockerfile
FROM otel/opentelemetry-collector-contrib:${UPSTREAM_VERSION} as builder

## Build RedHat compliant image
FROM registry.access.redhat.com/ubi9/ubi:9.4
ARG UPSTREAM_VERSION
ARG RELEASE

LABEL name="Opentelemetry-collector" \
vendor="Sumo Logic" \
version="${UPSTREAM_VERSION}" \
release="${RELEASE}" \
summary="UBI based opentelemetry-collector" \
description="The OpenTelemetry Collector offers a vendor-agnostic implementation on how to receive, process and export telemetry data." \
maintainer="[email protected]"

ADD https://raw.githubusercontent.com/open-telemetry/opentelemetry-collector/v${UPSTREAM_VERSION}/LICENSE \
/licenses/LICENSE

ARG USER_UID=10001
USER ${USER_UID}

COPY --from=builder /etc/ssl/certs/ca-certificates.crt /etc/ssl/certs/ca-certificates.crt
COPY --from=builder /otelcol-contrib /otelcontribcol
EXPOSE 55680 55679
ENTRYPOINT ["/otelcontribcol"]
CMD ["--config", "/etc/otel/config.yaml"]
5 changes: 5 additions & 0 deletions opentelemetry-collector/Makefile
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
#!/usr/bin/make -f

VERSION_PREFIX := ""

include ../Makefile.common

0 comments on commit 8244d91

Please sign in to comment.