From 73a7bfc10237f606376d270066c5c44dcd7400de Mon Sep 17 00:00:00 2001 From: Philipp Spinnler Date: Wed, 18 Sep 2024 11:47:56 +0200 Subject: [PATCH] added locale --- Dockerfile | 9 +++++++++ app/plugins/ical.py | 2 +- 2 files changed, 10 insertions(+), 1 deletion(-) diff --git a/Dockerfile b/Dockerfile index e4491b6..a7785e5 100644 --- a/Dockerfile +++ b/Dockerfile @@ -8,6 +8,15 @@ FROM python:3.12-slim WORKDIR /app COPY --from=builder /app/requirements.txt . RUN pip install --no-cache-dir -r requirements.txt + +RUN apt-get update && \ + apt-get install -y locales && \ + locale-gen de_CH.UTF-8 + +ENV LANG=de_CH.UTF-8 +ENV LANGUAGE=de_CH:de +ENV LC_ALL=de_CH.UTF-8 + COPY . . EXPOSE 8000 ENV PYTHONUNBUFFERED=1 diff --git a/app/plugins/ical.py b/app/plugins/ical.py index 6b91ef4..75ca038 100644 --- a/app/plugins/ical.py +++ b/app/plugins/ical.py @@ -8,7 +8,7 @@ from app import config local_time_zone = pytz.timezone("Europe/Zurich") -locale.setlocale(locale.LC_TIME, "de_DE.UTF-8") +locale.setlocale(locale.LC_TIME, "de_CH.UTF-8") def parse_webcal(url):