From 9e0efeb092bcc7713dc0ef6887d3e3934d2ae29a Mon Sep 17 00:00:00 2001 From: Pete Matsyburka Date: Wed, 1 Apr 2026 10:29:31 +0300 Subject: [PATCH] fix unicode in stamp --- Dockerfile | 17 +++++++---------- 1 file changed, 7 insertions(+), 10 deletions(-) diff --git a/Dockerfile b/Dockerfile index 969084aa..fedff0f5 100644 --- a/Dockerfile +++ b/Dockerfile @@ -2,20 +2,17 @@ FROM ruby:4.0.1-alpine AS download WORKDIR /fonts -RUN apk --no-cache add fontforge wget && \ +RUN apk --no-cache add wget && \ wget https://github.com/satbyy/go-noto-universal/releases/download/v7.0/GoNotoKurrent-Regular.ttf && \ wget https://github.com/satbyy/go-noto-universal/releases/download/v7.0/GoNotoKurrent-Bold.ttf && \ wget https://github.com/impallari/DancingScript/raw/master/fonts/DancingScript-Regular.otf && \ - wget https://cdn.jsdelivr.net/gh/notofonts/notofonts.github.io/fonts/NotoSansSymbols2/hinted/ttf/NotoSansSymbols2-Regular.ttf && \ - wget https://github.com/Maxattax97/gnu-freefont/raw/master/ttf/FreeSans.ttf && \ - wget https://github.com/impallari/DancingScript/raw/master/OFL.txt && \ + wget https://raw.githubusercontent.com/impallari/DancingScript/master/OFL.txt && \ + wget https://raw.githubusercontent.com/notofonts/noto-fonts/refs/heads/main/LICENSE && \ wget -O /model.onnx "https://github.com/docusealco/fields-detection/releases/download/2.0.0/model_704_int8.onnx" && \ wget -O pdfium-linux.tgz "https://github.com/bblanchon/pdfium-binaries/releases/latest/download/pdfium-linux-musl-$(uname -m | sed 's/x86_64/x64/;s/aarch64/arm64/').tgz" && \ mkdir -p /pdfium-linux && \ tar -xzf pdfium-linux.tgz -C /pdfium-linux -RUN fontforge -lang=py -c 'font1 = fontforge.open("FreeSans.ttf"); font2 = fontforge.open("NotoSansSymbols2-Regular.ttf"); font1.mergeFonts(font2); font1.generate("FreeSans.ttf")' - FROM ruby:4.0.1-alpine AS webpack ENV RAILS_ENV=production @@ -51,7 +48,7 @@ ENV OPENSSL_CONF=/etc/openssl_legacy.cnf WORKDIR /app -RUN apk add --no-cache libpq vips redis vips-heif ttf-freefont onnxruntime && mkdir /fonts && rm /usr/share/fonts/freefont/FreeSans.otf +RUN apk add --no-cache libpq vips redis vips-heif fontconfig onnxruntime RUN addgroup -g 2000 docuseal && adduser -u 2000 -G docuseal -s /bin/sh -D -h /home/docuseal docuseal @@ -82,14 +79,14 @@ COPY --chown=docuseal:docuseal ./tmp ./tmp COPY --chown=docuseal:docuseal LICENSE LICENSE_ADDITIONAL_TERMS README.md Rakefile config.ru .version ./ COPY --chown=docuseal:docuseal .version ./public/version -COPY --chown=docuseal:docuseal --from=download /fonts/GoNotoKurrent-Regular.ttf /fonts/GoNotoKurrent-Bold.ttf /fonts/DancingScript-Regular.otf /fonts/OFL.txt /fonts -COPY --from=download /fonts/FreeSans.ttf /usr/share/fonts/freefont +COPY --chown=docuseal:docuseal --from=download /fonts/GoNotoKurrent-Regular.ttf /fonts/GoNotoKurrent-Bold.ttf /fonts/DancingScript-Regular.otf /fonts/OFL.txt /fonts/LICENSE /fonts/ COPY --from=download /pdfium-linux/lib/libpdfium.so /usr/lib/libpdfium.so COPY --from=download /pdfium-linux/licenses/pdfium.txt /usr/lib/libpdfium-LICENSE.txt COPY --chown=docuseal:docuseal --from=download /model.onnx /app/tmp/model.onnx COPY --chown=docuseal:docuseal --from=webpack /app/public/packs ./public/packs -RUN ln -s /fonts /app/public/fonts && \ +RUN mkdir -p /app/public/fonts && ln -s /fonts/DancingScript-Regular.otf /app/public/fonts/ && \ + mkdir -p /usr/share/fonts/noto && ln -s /fonts/GoNotoKurrent-Regular.ttf /usr/share/fonts/noto/ && ln -s /fonts/GoNotoKurrent-Bold.ttf /usr/share/fonts/noto/ && fc-cache -f && \ bundle exec bootsnap precompile -j 1 --gemfile app/ lib/ && \ chown -R docuseal:docuseal /app/tmp/cache