compress static files in parallel

This commit is contained in:
Daniel Micay 2021-07-21 16:43:49 -04:00
parent dc00b338c6
commit 265576f637

View File

@ -11,6 +11,5 @@ cp --remove-destination webapps/element/config.json static_tmp/config.json
cp nginx/nginx.conf nginx.conf.tmp
find static_tmp -regex '.+\.\(css\|html\|ico\|js\|json\|map\|svg\|txt\|webmanifest\|xml\|wasm\)' \
-exec zopfli {} \; -exec touch -r {} {}.gz \; \
-exec brotli -k {} \;
find static_tmp -regex '.+\.\(css\|html\|ico\|js\|json\|map\|svg\|txt\|webmanifest\|xml\|wasm\)' |
parallel "brotli -k {}; zopfli {} && touch -r {} {}.gz"