Cookiecutter-django: ./manage.py compilemessages doesn't work with docker

Created on 17 Nov 2016  路  1Comment  路  Source: pydanny/cookiecutter-django

Hi,
I've been working with django cookiecutter for sometime now. I'm working on a project where we provide the site in 3 languages. I use docker for deployment and I was just trying to run:
docker-compose run django python manage.py compilemessages

but I got this error
CommandError: Can't find msgfmt. Make sure you have GNU gettext tools 0.15 or newer installed.

I tried adding this line to the django dockerfile
RUN apt-get install gettext libgettextpo-dev
but I got another error
Package 'gettext' has no installation candidate
Unable to locate package libgettextpo-dev

I think this is because the Python image isn't built on ubuntu. I'm not sure what's the alternative.
I'm still looking but I thought about asking here in case someone else came across the same problem.

Thanks guys.

Most helpful comment

So the problem was easier than I thought :)
I just had to apt-get update
so the command I added is
RUN apt-get update && apt-get install -y gettext libgettextpo-dev

>All comments

So the problem was easier than I thought :)
I just had to apt-get update
so the command I added is
RUN apt-get update && apt-get install -y gettext libgettextpo-dev

Was this page helpful?
0 / 5 - 0 ratings

Related issues

audreyfeldroy picture audreyfeldroy  路  4Comments

pygabo picture pygabo  路  3Comments

huydbui picture huydbui  路  3Comments

yunti picture yunti  路  4Comments

vladimirmyshkovski picture vladimirmyshkovski  路  4Comments