@@ -6,19 +6,17 @@ ADD --link --chown=101:1001 https://nginx.org/keys/nginx_signing.key nginx_signi
66ADD --link --chown=101 :1001 build/ubi/repos/nginx.repo nginx.repo
77ADD --link --chown=101 :1001 build/ubi/repos/agent.repo agent.repo
88
9- FROM redhat/ubi9-minimal:9.6 AS ubi-minimal
10-
119FROM ghcr.io/nginx/dependencies/nginx-ubi:ubi9@sha256:01a32246761b9bbe47a6a29bcd8ca6e9b6e331b3bdfa372d8987b622276f7025 AS ubi9-packages
1210
13- FROM ubi -minimal AS ubi-nginx
11+ FROM redhat/ubi9 -minimal:9.6 AS ubi-nginx
1412
1513# renovate: datasource=github-tags depName=nginx/agent
1614ARG NGINX_AGENT_VERSION=v3.3.1
1715ARG NJS_DIR
1816ARG NGINX_CONF_DIR
1917ARG BUILD_AGENT
2018
21- LABEL name="F5 NGINX Gateway Fabric NGINX" \
19+ LABEL name="F5 NGINX Gateway Fabric NGINX OSS " \
22202321 vendor="F5 NGINX" \
2422 summary="NGINX Gateway Fabric" \
@@ -29,7 +27,7 @@ LABEL name="F5 NGINX Gateway Fabric NGINX" \
2927
3028COPY --link --chown=101 :1001 LICENSE /licenses/
3129
32- # Install NGINX with OTEL support using the same approach as NGINX IC
30+ # Install NGINX with packages
3331RUN --mount=type=bind,from=nginx-files,src=nginx_signing.key,target=/tmp/nginx_signing.key \
3432 --mount=type=bind,from=nginx-files,src=nginx.repo,target=/etc/yum.repos.d/nginx.repo \
3533 --mount=type=bind,from=nginx-files,src=agent.repo,target=/etc/yum.repos.d/agent.repo \
@@ -54,20 +52,18 @@ RUN mkdir -p /usr/lib/nginx/modules /var/run/nginx /usr/lib64/nginx/modules \
5452 # Forward request and error logs to docker log collector
5553 && ln -sf /dev/stdout /var/log/nginx/access.log \
5654 && ln -sf /dev/stderr /var/log/nginx/error.log \
57- && mv /usr/lib64/nginx/modules/ngx_* /usr/lib/nginx/modules/ \
58- # Set proper permissions for nginx user
59- && chown -R 101 :1001 /etc/nginx /var/cache/nginx /var/log/nginx /var/run/nginx
55+ && mv /usr/lib64/nginx/modules/ngx_* /usr/lib/nginx/modules/
56+
57+ # Set proper permissions for nginx user
58+ RUN chown -R 101 :1001 /etc/nginx /var/cache/nginx
6059
6160# Copy configuration files and scripts
6261COPY build/entrypoint.sh /agent/entrypoint.sh
63- COPY ${ NJS_DIR} /httpmatches.js /usr/lib/nginx/modules/njs/httpmatches.js
62+ COPY ${ NJS_DIR} / /usr/lib/nginx/modules/njs/
6463COPY ${ NGINX_CONF_DIR} /nginx.conf /etc/nginx/nginx.conf
6564COPY ${ NGINX_CONF_DIR} /grpc-error-locations.conf /etc/nginx/grpc-error-locations.conf
6665COPY ${ NGINX_CONF_DIR} /grpc-error-pages.conf /etc/nginx/grpc-error-pages.conf
6766
68- # Set executable permissions
69- RUN chmod +x /agent/entrypoint.sh && chown 101 :1001 /agent/entrypoint.sh
70-
7167# Switch to non-root user
7268USER 101 :1001
7369
0 commit comments