25개 이상의 토픽을 선택하실 수 없습니다. Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

Dockerfile 764 B

12345678910111213141516171819202122232425262728293031323334
  1. FROM python:3.9-slim
  2. RUN useradd --create-home --shell /bin/bash kosmorro
  3. WORKDIR /home/kosmorro
  4. ENV PATH="/home/kosmorro:${PATH}"
  5. # Prepare environment
  6. RUN python -m pip install --upgrade pip
  7. RUN pip install pipenv
  8. COPY Pipfile.lock .
  9. RUN pipenv sync && pipenv run pip freeze > requirements.txt
  10. # Add files
  11. RUN pip install -r requirements.txt
  12. COPY _kosmorro/ _kosmorro/
  13. COPY kosmorro .
  14. # Compile the translations
  15. RUN pip install Babel
  16. COPY setup.py setup.py
  17. COPY setup.cfg setup.cfg
  18. COPY README.md README.md
  19. RUN python setup.py compile_catalog
  20. # Clean the image
  21. RUN rm setup.py setup.cfg README.md && \
  22. rm _kosmorro/locales/messages.pot _kosmorro/locales/*/LC_MESSAGES/messages.po && \
  23. pip uninstall --yes Babel pipenv
  24. USER kosmorro
  25. CMD ["bash"]