Skip to content

Instantly share code, notes, and snippets.

@kvigen
Created September 26, 2014 03:12
Show Gist options
  • Save kvigen/5c782a2141ca7e071b34 to your computer and use it in GitHub Desktop.
Save kvigen/5c782a2141ca7e071b34 to your computer and use it in GitHub Desktop.
Mongo Container in Prod
FROM ubuntu:precise
RUN apt-get -qq update && apt-get -y install wget && \
wget http://fastdl.mongodb.org/linux/mongodb-linux-x86_64-2.4.0.tgz && \
tar xzf mongodb-linux-x86_64-2.4.0.tgz && \
install -t /usr/bin mongodb-linux-x86_64-2.4.0/bin/* && \
mkdir -p /data/db /var/lib/mongodb/ && \
rm mongodb-linux-x86_64-2.4.0.tgz && \
rm -rf mongodb-linux-x86_64-2.4.0
EXPOSE 27017
ENTRYPOINT ["usr/bin/mongod"]
CMD ["--noprealloc", "--smallfiles", "--nojournal", "--replSet", "TailTest"]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment