Skip to content
Snippets Groups Projects
Commit e16f9b57 authored by Joe Ferguson's avatar Joe Ferguson Committed by Konstantin Pavlov
Browse files

Adjust scanelf to ignore local libs

parent 48a4c531
No related branches found
No related tags found
No related merge requests found
...@@ -118,11 +118,10 @@ RUN GPG_KEYS=B0F4253373F8F6F510D42178520A9993A1C052F8 \ ...@@ -118,11 +118,10 @@ RUN GPG_KEYS=B0F4253373F8F6F510D42178520A9993A1C052F8 \
&& mv /usr/bin/envsubst /tmp/ \ && mv /usr/bin/envsubst /tmp/ \
\ \
&& runDeps="$( \ && runDeps="$( \
scanelf --needed --nobanner /usr/sbin/nginx /usr/lib/nginx/modules/*.so /tmp/envsubst \ scanelf --needed --nobanner --format '%n#p' /usr/sbin/nginx /usr/lib/nginx/modules/*.so /tmp/envsubst \
| awk '{ gsub(/,/, "\nso:", $2); print "so:" $2 }' \ | tr ',' '\n' \
| sort -u \
| xargs -r apk info --installed \
| sort -u \ | sort -u \
| awk 'system("[ -e /usr/local/lib/" $1 " ]") == 0 { next } { print "so:" $1 }' \
)" \ )" \
&& apk add --no-cache --virtual .nginx-rundeps $runDeps \ && apk add --no-cache --virtual .nginx-rundeps $runDeps \
&& apk del .build-deps \ && apk del .build-deps \
......
...@@ -118,11 +118,10 @@ RUN GPG_KEYS=B0F4253373F8F6F510D42178520A9993A1C052F8 \ ...@@ -118,11 +118,10 @@ RUN GPG_KEYS=B0F4253373F8F6F510D42178520A9993A1C052F8 \
&& mv /usr/bin/envsubst /tmp/ \ && mv /usr/bin/envsubst /tmp/ \
\ \
&& runDeps="$( \ && runDeps="$( \
scanelf --needed --nobanner /usr/sbin/nginx /usr/lib/nginx/modules/*.so /tmp/envsubst \ scanelf --needed --nobanner --format '%n#p' /usr/sbin/nginx /usr/lib/nginx/modules/*.so /tmp/envsubst \
| awk '{ gsub(/,/, "\nso:", $2); print "so:" $2 }' \ | tr ',' '\n' \
| sort -u \
| xargs -r apk info --installed \
| sort -u \ | sort -u \
| awk 'system("[ -e /usr/local/lib/" $1 " ]") == 0 { next } { print "so:" $1 }' \
)" \ )" \
&& apk add --no-cache --virtual .nginx-rundeps $runDeps \ && apk add --no-cache --virtual .nginx-rundeps $runDeps \
&& apk del .build-deps \ && apk del .build-deps \
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment