# Copyright The OpenTelemetry Authors # SPDX-License-Identifier: Apache-2.0 FROM nginxinc/nginx-unprivileged:1.29.0-alpine3.22 USER 0 RUN printf "%s%s%s%s\n" \ "@nginx " \ "http://nginx.org/packages/mainline/alpine/v" \ `egrep -o '^[0-9]+\.[0-9]+' /etc/alpine-release` \ "/main" \ | tee -a /etc/apk/repositories RUN apk update && \ apk add nginx-module-otel@nginx USER 101 COPY src/image-provider/static/ /static/ COPY src/image-provider/nginx.conf.template /nginx.conf.template EXPOSE ${IMAGE_PROVIDER_PORT} STOPSIGNAL SIGQUIT # Start nginx CMD ["/bin/sh" , "-c" , "envsubst '$OTEL_COLLECTOR_HOST $IMAGE_PROVIDER_PORT $OTEL_COLLECTOR_PORT_GRPC $OTEL_SERVICE_NAME' < /nginx.conf.template > /etc/nginx/nginx.conf && cat /etc/nginx/nginx.conf && exec nginx -g 'daemon off;'"]