Files
marko a9097ad96c nginx-metrics: expose status codes metrics
Combine connections metrics from stub_status and create status codes
metrics. Expose everything under /metrics endpoint of eth-rpc-proxy.
Remove the prometheus nginx metrics exporter since it is replaced.
2025-11-14 14:48:56 +01:00

30 lines
1.1 KiB
Docker

FROM openresty/openresty:alpine
# Install dependencies and configure
RUN apk add --no-cache ca-certificates curl perl build-base wget tar yaml-dev git && \
update-ca-certificates && \
/usr/local/openresty/bin/opm install ledgetech/lua-resty-http && \
cd /tmp && \
wget https://luarocks.org/releases/luarocks-3.12.2.tar.gz && \
tar -xzf luarocks-3.12.2.tar.gz && \
cd luarocks-3.12.2 && \
./configure --prefix=/usr/local --with-lua=/usr/local/openresty/luajit && \
make && make install && \
cd / && rm -rf /tmp/luarocks-3.12.2* && \
luarocks install lyaml && \
luarocks install lua-resty-mlcache && \
luarocks install lua-resty-redis
# Copy configuration files
COPY nginx.conf /usr/local/openresty/nginx/conf/nginx.conf
COPY metrics.conf /usr/local/openresty/nginx/conf/metrics.conf
# cache_metrics.conf removed - metrics now served by go-proxy-cache service
COPY providers.json /app/providers.json
COPY lua /usr/local/openresty/nginx/lua
# Specify the port to be used
EXPOSE 8080
# Nginx startup command
CMD ["openresty", "-g", "daemon off;"]