Dockerfile 1.4KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657
  1. FROM debian:jessie
  2. MAINTAINER contact@algoo.fr
  3. # TODO: See GOOD PRATICE (remove apt lists, cache, etc)
  4. # Install required packages
  5. RUN apt-get update -q \
  6. && DEBIAN_FRONTEND=noninteractive apt-get install -yq --no-install-recommends \
  7. git \
  8. locales \
  9. realpath \
  10. python3 \
  11. python3-dev \
  12. python3-pip \
  13. build-essential \
  14. libxml2-dev \
  15. libxslt1-dev \
  16. python-lxml \
  17. postgresql-server-dev-all \
  18. postgresql \
  19. postgresql-client \
  20. uwsgi \
  21. uwsgi-plugin-python3 \
  22. mysql-client \
  23. libmysqld-dev \
  24. sqlite3
  25. # Ensure UTF-8
  26. RUN locale-gen en_US.UTF-8 en_us \
  27. && dpkg-reconfigure locales \
  28. && locale-gen C.UTF-8 \
  29. && /usr/sbin/update-locale LANG=C.UTF-8
  30. ENV LANG C.UTF-8
  31. ENV LANGUAGE C.UTF-8
  32. ENV LC_ALL C.UTF-8
  33. # Download and install Tracim
  34. RUN git clone https://github.com/tracim/tracim.git \
  35. && cd /tracim/tracim \
  36. && python3 setup.py develop \
  37. && cd /tracim \
  38. && pip3 install -r install/requirements.txt\
  39. && pip3 install https://launchpad.net/oursql/py3k/py3k-0.9.4/+download/oursql-0.9.4.zip \
  40. && echo 20161216001
  41. # Prepare volumes
  42. RUN mkdir /etc/tracim \
  43. && mkdir /var/tracim
  44. VOLUME ["/etc/tracim", "/var/tracim"]
  45. COPY uwsgi.ini /tracim/tracim/uwsgi.ini.template
  46. COPY wsgi.py /tracim/tracim/wsgi.py
  47. COPY check_env_vars.sh /tracim/check_env_vars.sh
  48. COPY entrypoint.sh /tracim/entrypoint.sh
  49. CMD ["/tracim/entrypoint.sh"]