Skip to content

Instantly share code, notes, and snippets.

@nikos
Created June 16, 2015 10:00
Show Gist options
  • Star 2 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save nikos/eb27dce271f00cba2bb7 to your computer and use it in GitHub Desktop.
Save nikos/eb27dce271f00cba2bb7 to your computer and use it in GitHub Desktop.
MarkLogic Server 8.0-3 prepared to run with on an CentOS 6.6 Linux server, after container is started, go to http://localhost:8001/ to finish installation
FROM centos:centos6.6
MAINTAINER Niko Schmuck <niko.auto@nava.de>
# Install MarkLogic
RUN yum -y update &&\
yum groupremove 'Additional Development' 'E-mail server' 'Graphical Administration Tools' 'Perl Support' &&\
curl -O https://developer.marklogic.com/download/binaries/8.0/MarkLogic-8.0-3.x86_64.rpm &&\
yum -y install MarkLogic-8.0-3.x86_64.rpm &&\
rm MarkLogic-8.0-3.x86_64.rpm &&\
yum clean all
ENV MARKLOGIC_INSTALL_DIR /opt/MarkLogic
ENV MARKLOGIC_DATA_DIR /data
ENV MARKLOGIC_FSTYPE ext4
ENV MARKLOGIC_USER daemon
ENV MARKLOGIC_PID_FILE /var/run/MarkLogic.pid
ENV MARKLOGIC_MLCMD_PID_FILE /var/run/mlcmd.pid
ENV MARKLOGIC_UMASK 022
ENV PATH /usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/opt/MarkLogic/mlcmd/bin
ENV LD_PRELOAD /opt/MarkLogic/lib/libjemalloc.so.1
ENV LD_LIBRARY_PATH /opt/MarkLogic/lib:/data/Lib
# Define mountable directory
VOLUME ["/data"]
# Define working directory
WORKDIR /data
# Define default command (which avoids immediate shutdown)
CMD /opt/MarkLogic/bin/MarkLogic && tail -F /data/Logs/ErrorLog.txt
# Expose MarkLogic Server ports
EXPOSE 7997 7999 8000 8001 8002 8040 8041 8042 8043 8044
@nikos
Copy link
Author

nikos commented Jun 16, 2015

This is the base for the docker image: https://registry.hub.docker.com/u/nikos/centos-ml8/

@patrickmcelwee
Copy link

Niko, could you tell me what the LD_PRELOAD is doing?

@willhlaw
Copy link

Looks like the LD_PRELOAD 'trick' loads the specific malloc library before any other library from here: http://stackoverflow.com/questions/426230/what-is-the-ld-preload-trick.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment