LOADING
Dockerで「 Can't find msgfmt.」の対処法

① Dockerfileに以下を追加

RUN apt-get update && apt-get install -y gettext libgettextpo-dev


例:Dockerfile

FROM python:3.10

ENV PYTHONDONTWRITEBYTECODE 1
ENV PYTHONUNBUFFERED 1

WORKDIR /code

COPY Pipfile Pipfile.lock /code/
RUN pip install pipenv && pipenv install --system
RUN apt-get update && apt-get install -y gettext libgettextpo-dev
COPY . /code/



②ビルドする

$ docker compose up -d --build



Django translateで

$ docker compose exec web django-admin makemessages -l ja
favorite
chat_bubble 0
プロモーション