Files
deepl-christina/Dockerfile
Pascal Linxweiler dd6095d402 Scheer Enterprise Translation Tool
Node HTTP server that proxies the DeepL API and serves a single-page UI, plus
per-domain glossary management for the four Scheer entities. Runs on Node's
built-ins only; no dependencies.

Containerized for Dokploy: the domain -> glossary_id map is written to
DOMAINS_FILE (default /app/data/domains.json) so it can live on a mounted
volume and survive redeploys. See DEPLOY.md.

Co-Authored-By: Claude <noreply@anthropic.com>
2026-07-31 11:46:59 +02:00

28 lines
953 B
Docker

# Scheer Enterprise Translation Tool — container image.
# No dependencies to install (server.js only uses Node's built-ins), so the
# image just needs a Node runtime plus the two app files.
FROM node:18-alpine
WORKDIR /app
COPY server.js index.html package.json ./
# DEEPL_API_KEY is passed at runtime (docker run -e / --env-file, or the
# Dokploy "Environment" tab), never baked into the image.
#
# domains.json holds which DeepL glossary_id belongs to which domain and
# direction. It must live on a mounted volume, otherwise every redeploy
# builds a fresh filesystem and the mappings are lost. /app/data is a
# subdirectory so mounting it does not shadow the app files in /app.
ENV PORT=3000
ENV DOMAINS_FILE=/app/data/domains.json
RUN mkdir -p /app/data
VOLUME ["/app/data"]
EXPOSE 3000
HEALTHCHECK --interval=30s --timeout=5s --start-period=5s --retries=3 \
CMD wget -qO- http://127.0.0.1:3000/health || exit 1
CMD ["node", "server.js"]