File tree Expand file tree Collapse file tree 1 file changed +5
-1
lines changed
Expand file tree Collapse file tree 1 file changed +5
-1
lines changed Original file line number Diff line number Diff line change @@ -131,7 +131,11 @@ RUN GPG_KEYS=B0F4253373F8F6F510D42178520A9993A1C052F8 \
131131 && cp /usr/src/ModSecurity/unicode.mapping /etc/nginx/modsec.d \
132132 && sed -i -e 's/SecRuleEngine DetectionOnly/SecRuleEngine On/g' /etc/nginx/modsec.d/modsecurity.conf \
133133 && cd /etc/nginx/modsec.d \
134- && git clone --depth 1 https://github.com/SpiderLabs/owasp-modsecurity-crs \
134+ && CRS_VERSION=$(curl --silent "https://api.github.com/repos/SpiderLabs/owasp-modsecurity-crs/releases/latest" | grep '"tag_name":' | sed -E 's/.*"v([^"]+)".*/\1 /' ) \
135+ && curl -fSL https://github.com/SpiderLabs/owasp-modsecurity-crs/archive/v$CRS_VERSION.tar.gz -o owasp-modsecurity-crs.tar.gz \
136+ && tar -zxC ./ -f owasp-modsecurity-crs.tar.gz \
137+ && rm ./owasp-modsecurity-crs.tar.gz \
138+ && mv owasp-modsecurity-crs-$CRS_VERSION owasp-modsecurity-crs \
135139 && cd owasp-modsecurity-crs \
136140 && mv crs-setup.conf.example crs-setup.conf \
137141 && cd rules \
You can’t perform that action at this time.
0 commit comments