mirror of
https://github.com/phpmyadmin/docker.git
synced 2026-08-24 10:13:22 -05:00
Added extra sanity check + better output in case of failure
This commit is contained in:
@@ -39,7 +39,8 @@ RUN set -ex; \
|
||||
\
|
||||
apt-get purge -y --auto-remove -o APT::AutoRemove::RecommendsImportant=false; \
|
||||
rm -rf /var/lib/apt/lists/*; \
|
||||
ldd "$extdir"/*.so | grep -qzv "=> not found";
|
||||
ldd "$extdir"/*.so | grep -qzv "=> not found" || (echo "Sanity check failed: missing libraries:"; ldd "$extdir"/*.so | grep " => not found"; exit 1); \
|
||||
ldd "$extdir"/*.so | grep -q "libzip.so.* => .*/libzip.so.*" || (echo "Sanity check failed: libzip.so is not referenced"; ldd "$extdir"/*.so; exit 1);
|
||||
|
||||
# set recommended PHP.ini settings
|
||||
# see https://secure.php.net/manual/en/opcache.installation.php
|
||||
|
||||
+3
-1
@@ -30,6 +30,7 @@ RUN set -ex; \
|
||||
extdir="$(php -r 'echo ini_get("extension_dir");')"; \
|
||||
ldd "$extdir"/*.so \
|
||||
| awk '/=>/ { print $3 }' \
|
||||
| awk '{print $1} {system("realpath " $1)}' \
|
||||
| sort -u \
|
||||
| xargs -r dpkg-query -S \
|
||||
| cut -d: -f1 \
|
||||
@@ -38,7 +39,8 @@ RUN set -ex; \
|
||||
\
|
||||
apt-get purge -y --auto-remove -o APT::AutoRemove::RecommendsImportant=false; \
|
||||
rm -rf /var/lib/apt/lists/*; \
|
||||
ldd "$extdir"/*.so | grep -qzv "=> not found";
|
||||
ldd "$extdir"/*.so | grep -qzv "=> not found" || (echo "Sanity check failed: missing libraries:"; ldd "$extdir"/*.so | grep " => not found"; exit 1); \
|
||||
ldd "$extdir"/*.so | grep -q "libzip.so.* => .*/libzip.so.*" || (echo "Sanity check failed: libzip.so is not referenced"; ldd "$extdir"/*.so; exit 1);
|
||||
|
||||
# set recommended PHP.ini settings
|
||||
# see https://secure.php.net/manual/en/opcache.installation.php
|
||||
|
||||
+3
-1
@@ -30,6 +30,7 @@ RUN set -ex; \
|
||||
extdir="$(php -r 'echo ini_get("extension_dir");')"; \
|
||||
ldd "$extdir"/*.so \
|
||||
| awk '/=>/ { print $3 }' \
|
||||
| awk '{print $1} {system("realpath " $1)}' \
|
||||
| sort -u \
|
||||
| xargs -r dpkg-query -S \
|
||||
| cut -d: -f1 \
|
||||
@@ -38,7 +39,8 @@ RUN set -ex; \
|
||||
\
|
||||
apt-get purge -y --auto-remove -o APT::AutoRemove::RecommendsImportant=false; \
|
||||
rm -rf /var/lib/apt/lists/*; \
|
||||
ldd "$extdir"/*.so | grep -qzv "=> not found";
|
||||
ldd "$extdir"/*.so | grep -qzv "=> not found" || (echo "Sanity check failed: missing libraries:"; ldd "$extdir"/*.so | grep " => not found"; exit 1); \
|
||||
ldd "$extdir"/*.so | grep -q "libzip.so.* => .*/libzip.so.*" || (echo "Sanity check failed: libzip.so is not referenced"; ldd "$extdir"/*.so; exit 1);
|
||||
|
||||
# set recommended PHP.ini settings
|
||||
# see https://secure.php.net/manual/en/opcache.installation.php
|
||||
|
||||
Reference in New Issue
Block a user