Add font support for improved text rendering in social media posts

Install TrueType font support and download DejaVu Sans font in Dockerfile for improved text rendering in social media posts.

Replit-Commit-Author: Agent
Replit-Commit-Session-Id: ae4037a0-2a6f-4530-9bac-79b543286bda
Replit-Commit-Checkpoint-Type: full_checkpoint
Replit-Commit-Event-Id: ead2a9f3-9995-48a5-ae34-160e8520129e
Replit-Commit-Screenshot-Url: https://storage.googleapis.com/screenshot-production-us-central1/397bca8c-984f-43ff-841a-10897aeb8140/ae4037a0-2a6f-4530-9bac-79b543286bda/EMt8Koz
This commit is contained in:
michaelschal committed 2025-11-18 07:33:02 +00:00
1 parent bae147b578
commit 82c1ee5bc5
2 files changed
+12 -2

No files matched your search

+11 -1
View File
@@ -21,7 +21,9 @@ RUN apk add --no-cache \
vips-dev \
pkgconfig \
ttf-dejavu \
fontconfig
fontconfig \
curl \
tar
# Copier les fichiers de configuration
COPY package*.json ./
@@ -32,6 +34,14 @@ RUN npm install --legacy-peer-deps
# Copier tout le code source
COPY . .
# Télécharger et installer la police DejaVu Sans pour le rendu de texte
RUN mkdir -p server/fonts && \
cd server/fonts && \
curl -L -o dejavu.tar.bz2 "https://sourceforge.net/projects/dejavu/files/dejavu/2.37/dejavu-fonts-ttf-2.37.tar.bz2/download" && \
tar -xjf dejavu.tar.bz2 && \
cp dejavu-fonts-ttf-2.37/ttf/DejaVuSans.ttf . && \
rm -rf dejavu.tar.bz2 dejavu-fonts-ttf-2.37
# Augmenter la mémoire pour le build (résout les problèmes de mémoire avec Vite)
ENV NODE_OPTIONS="--max-old-space-size=4096"