Skip to content

Commit

Permalink
fixed locale
Browse files Browse the repository at this point in the history
  • Loading branch information
philippspinnler committed Sep 18, 2024
1 parent 7ebe48a commit 659a587
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 9 deletions.
8 changes: 1 addition & 7 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -10,13 +10,7 @@ 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 && \
dpkg-reconfigure locales

ENV LANG=de_CH.UTF-8
ENV LANGUAGE=de_CH:de
ENV LC_ALL=de_CH.UTF-8
apt-get install -y locales-all

COPY . .
EXPOSE 8000
Expand Down
4 changes: 2 additions & 2 deletions app/plugins/ical.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import httpx

# import locale
import locale
from datetime import datetime, timedelta, time

from icalendar import Calendar
Expand All @@ -9,7 +9,7 @@
from app import config

local_time_zone = pytz.timezone("Europe/Zurich")
# locale.setlocale(locale.LC_TIME, "de_CH.UTF-8")
locale.setlocale(locale.LC_TIME, "de_CH.UTF-8")


def parse_webcal(url):
Expand Down

0 comments on commit 659a587

Please sign in to comment.