kolla/docker_templates/mongodb/Dockerfile.j2
Sam Yaple cfe6d6200d Add mongodb to docker_templates
Change-Id: I0adbc986f02b22c90019b76784153a9accac663f
Partially-Implements: blueprint dockerfile-template
2015-08-17 07:38:59 +00:00

24 lines
601 B
Django/Jinja

FROM {{ namespace }}/{{ base_distro }}-{{ install_type }}-base:{{ tag }}
MAINTAINER Kolla Project (https://launchpad.net/kolla)
{% if base_distro in ['fedora', 'centos', 'oraclelinux'] %}
RUN yum -y install \
mongodb \
mongodb-server \
&& yum clean all
{% elif base_distro in ['ubuntu', 'debian'] %}
RUN echo '{{ install_type }} not yet available for {{ base_distro }}' \
&& /bin/false
{% endif %}
RUN mkdir -p /data/db
VOLUME /data/db
VOLUME /var/log/mongodb
ENTRYPOINT exec /bin/mongod --dbpath /data/db --logpath /var/log/mongodb/mongo.log --noprealloc --smallfiles