exchange

Base system with REST service to issue digital coins, run by the payment service provider
Log | Files | Refs | Submodules | README | LICENSE

commit ce3c5a1d2e8251cdcc3a5e3bb1ce8a7d85febcc3
parent d9f6dc51cff7424dfc747bb16e1744416477697a
Author: Florian Dold <florian@dold.me>
Date:   Sun, 27 Jul 2025 12:58:11 +0200

Revert "debian: properly compress SPA files"

This reverts commit d9f6dc51cff7424dfc747bb16e1744416477697a.

Diffstat:
Mdebian/taler-exchange.postinst | 27++++++++-------------------
1 file changed, 8 insertions(+), 19 deletions(-)

diff --git a/debian/taler-exchange.postinst b/debian/taler-exchange.postinst @@ -95,25 +95,14 @@ configure) /etc/taler-exchange/secrets/exchange-db.secret.conf fi - # Check if we have compression commands - zstd --version >/dev/null 2>&1; have_zstd=$(( ! $? )) - gzip --version >/dev/null 2>&1; have_gzip=$(( ! $? )) - - # Generate compressed versions of the SPA files. - # Remove existing files if compression tool is not available, - # as previous package version wrongly generated empty files - # when the tool was missing. - for n in /usr/share/taler-exchange/*-spa/*.{css,js,html,json}; do - if [[ $have_gzip = 1 ]]; then - gzip -f --best "$n" > "$n.gz" - else - rm -f "$n.gz" - fi - if [[ $have_zstd = 1 ]]; then - zstd -f -19 "$n" > "$n.zstd" - else - rm -f "$n.zstd" - fi + # Try to generate compressed versions of the SPAs + for n in forms.json index.css index.js index.html + do + TDIR="/usr/share/taler-exchange/" + gzip --best - < "${TDIR}/aml-spa/$n" > "${TDIR}/aml-spa/$n.gz" || true + gzip --best - < "${TDIR}/kyc-spa/$n" > "${TDIR}/kyc-spa/$n.gz" || true + zstd -19 - < "${TDIR}/aml-spa/$n" > "${TDIR}/aml-spa/$n.zstd" || true + zstd -19 - < "${TDIR}/kyc-spa/$n" > "${TDIR}/kyc-spa/$n.zstd" || true done ;;