Skip to content

Commit 764ba10

Browse files
committed
- reformat code
- removed dev libs
1 parent ca025ce commit 764ba10

File tree

1 file changed

+13
-3
lines changed

1 file changed

+13
-3
lines changed

Dockerfile

Lines changed: 13 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@ WORKDIR $WORKING_DIRECTORY
99

1010
# ENV build variables
1111
ENV LANG C.UTF-8
12+
ENV LC_ALL=C
1213
ENV NGINX_VERSION=1.11.1
1314
ENV MODSEC_VERSION=2.9.1
1415
ENV NGINX_BASE_CONFIG="\
@@ -56,7 +57,6 @@ ENV NGINX_BASE_CONFIG="\
5657
"
5758
ENV NGINX_CONFIG_MODSECURITY=" --add-module=$WORKING_DIRECTORY/ModSecurity/nginx/modsecurity "
5859
ENV NGINX_CONFIG_EXTRA_MODULES=" --with-http_realip_module --with-http_ssl_module "
59-
ENV LC_ALL=C
6060

6161
# 1 Install required dependencies
6262
# 2 Compile Mod Security
@@ -120,8 +120,18 @@ RUN \
120120
rm /etc/nginx/nginx.conf && \
121121
cd .. && \
122122
echo "#### Clean solution ####" && \
123-
apk del build-base linux-headers git autoconf automake && \
124-
rm -rf $WORKING_DIRECTORY modsecurity.conf-recommended nginx-${NGINX_VERSION}.tar.gz nginx-${NGINX_VERSION} owasp-modsecurity-crs.tar.gz
123+
apk del \
124+
build-base
125+
linux-headers
126+
git
127+
autoconf
128+
automake
129+
*.dev && \
130+
rm -rf $WORKING_DIRECTORY \
131+
modsecurity.conf-recommended \
132+
nginx-${NGINX_VERSION}.tar.gz \
133+
nginx-${NGINX_VERSION} \
134+
owasp-modsecurity-crs.tar.gz
125135

126136

127137
# Set workdir

0 commit comments

Comments
 (0)