Opentelemetry module build (#8585)
* nginx opentelemetry modules * revert sha check
This commit is contained in:
parent
b0d198252f
commit
24925ccd2b
3 changed files with 284 additions and 63 deletions
|
|
@ -13,16 +13,33 @@
|
|||
# limitations under the License.
|
||||
|
||||
|
||||
FROM alpine:3.14.6 as builder
|
||||
FROM alpine:3.14.6 as base
|
||||
|
||||
COPY . /
|
||||
RUN mkdir -p /opt/third_party/install
|
||||
COPY . /opt/third_party/
|
||||
|
||||
# install build tools
|
||||
RUN apk update \
|
||||
&& apk upgrade \
|
||||
&& apk add -U bash \
|
||||
&& /build.sh
|
||||
&& bash /opt/third_party/build.sh -p
|
||||
|
||||
FROM alpine:3.14.6
|
||||
# install gRPC
|
||||
FROM base as grpc
|
||||
RUN bash /opt/third_party/build.sh -g v1.43.2
|
||||
|
||||
COPY --from=builder init_module.sh /usr/local/bin/init_module.sh
|
||||
COPY --from=builder /etc/nginx/modules /etc/nginx/modules
|
||||
# install OpenTelemetry-cpp
|
||||
FROM base as otel-cpp
|
||||
COPY --from=grpc /opt/third_party/install/ /usr
|
||||
RUN bash /opt/third_party/build.sh -o v1.3.0
|
||||
|
||||
# install otel_ngx_module.so
|
||||
FROM base as nginx
|
||||
COPY --from=grpc /opt/third_party/install/ /usr
|
||||
COPY --from=otel-cpp /opt/third_party/install/ /usr
|
||||
RUN bash /opt/third_party/build.sh -n
|
||||
|
||||
FROM alpine:3.14.6
|
||||
COPY --from=base /opt/third_party/init_module.sh /usr/local/bin/init_module.sh
|
||||
COPY --from=nginx /etc/nginx/modules /etc/nginx/modules
|
||||
COPY --from=nginx /opt/third_party/install/lib /usr/lib
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue