aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJenkins <jenkins@review.openstack.org>2015-08-17 20:18:31 +0000
committerGerrit Code Review <review@openstack.org>2015-08-17 20:18:31 +0000
commitac4a6f620f00c985706d71e2c8f214812c79cb41 (patch)
treee0c3bf99f5599f4c7f41f5b6da8e103660fb4bfe
parentb8296c7ca9b68a27d7f95d0a45bbc4a92efb6cdd (diff)
parentcfe6d6200d503bfb1ace77dec05b835d7b4aab94 (diff)
downloadkolla-ac4a6f620f00c985706d71e2c8f214812c79cb41.tar.gz
kolla-ac4a6f620f00c985706d71e2c8f214812c79cb41.zip
Merge "Add mongodb to docker_templates"
-rw-r--r--docker_templates/mongodb/Dockerfile.j223
1 files changed, 23 insertions, 0 deletions
diff --git a/docker_templates/mongodb/Dockerfile.j2 b/docker_templates/mongodb/Dockerfile.j2
new file mode 100644
index 000000000..91e880007
--- /dev/null
+++ b/docker_templates/mongodb/Dockerfile.j2
@@ -0,0 +1,23 @@
+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