blob: f24062260d9bd1b0649e1bfed56f579b956e6b1a (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
|
FROM startx/fedora
MAINTAINER Christophe LARUE <dev@startx.fr>
USER root
RUN dnf -y install mongodb mongodb-server libmongo-client rsyslog-mongodb && \
dnf clean all
ENV MONGOCONF=/etc/mongodb.conf \
STARTUPLOG=/data/logs/mongodb/startup.log \
LOG_PATH=/data/logs/mongodb \
DATA_PATH=/data/mongodb
COPY mongodb.conf $MONGOCONF
COPY *.sh /bin/
RUN chmod 775 /bin/run.sh && \
chmod ug+r $MONGOCONF && \
mkdir -p $DATA_PATH && \
mkdir -p $LOG_PATH && \
touch $STARTUPLOG
RUN chown -R mongodb:mongodb $DATA_PATH $LOG_PATH
EXPOSE 27017 28017
VOLUME [$DATA_PATH,$LOG_PATH]
CMD ["/bin/run.sh"]
|