Public Repository

Last pushed: 2 years ago
Short Description
mongodb 2.4.5
Full Description

Instructions

Mongodb 2.4.5
tag: latest

To run:

MongoDB Server

$ docker run -d -v /home/mongo:/data -p 27017:27017 -p 28017:28017  sahilsk/mongo_2.4.5  mongod --rest 

MongoDB Shell client

$ docker run --rm -it sahilsk/mongo_2.4.5 mongo

Dockerfile

#
# MongoDB 2.4.5 Dockerfile
#
#
FROM ubuntu:12.04
MAINTAINER stackexpress "http://stackexpress.com"
RUN apt-get update
RUN apt-get install -y make gcc wget
RUN wget http://fastdl.mongodb.org/linux/mongodb-linux-x86_64-2.4.5.tgz -O /tmp/pkg.tar.gz

RUN ln -s /opt/mongodb/bin/mongo /usr/local/bin/mongo
RUN ln -s /opt/mongodb/bin/mongod /usr/local/bin/mongod
RUN (cd /tmp && tar zxf pkg.tar.gz && mv mongodb-* /opt/mongodb)
RUN rm -rf /tmp/*

RUN mkdir -p /data/db
# Define mountable directories.
VOLUME ["/data/db"]

# Define working directory.
WORKDIR /data

EXPOSE 27017
EXPOSE 28017
CMD ["/opt/mongodb/bin/mongod", "--rest"]

Licence

Licence: MIT

Docker Pull Command
Owner
sahilsk