############################################################ # Dockerfile to build LINDAT Dspace container images # Based on Ubuntu ############################################################ FROM ubuntu LABEL maintainer="Alexander König <Alexander.Koenig@eurac.edu>" # install cpanm and dependencies RUN apt-get update &&\ apt-get -y upgrade &&\ apt-get -y install make gcc wget cpanminus RUN cpanm File::Spec::Functions RUN cpanm Term::ReadLine # install jdk, ant, psql, mvn, make, libxml, xsltproc, zip, wget RUN apt-get -y install openjdk-8-jdk ant maven libxml2-utils xsltproc unzip curl # install convenience apps for debug purposes (vim and jsbeautifier) RUN apt-get -y install vim RUN apt-get -y install python-pip RUN pip install --upgrade pip RUN pip install jsbeautifier COPY commul-customization/__init__.py /usr/local/lib/python2.7/dist-packages/jsbeautifier/ # set up a proper locale RUN apt-get -y install locales RUN locale-gen en_US.UTF-8 COPY commul-customization/default_locale /etc/default/locale RUN chmod 0755 /etc/default/locale ENV LC_ALL=en_US.UTF-8 ENV LANG=en_US.UTF-8 ENV LANGUAGE=en_US.UTF-8 # get aai project RUN apt-get install -y git RUN git clone https://github.com/ufal/lindat-aai-discovery.git /opt/repository/sources/lindat-aai-discovery # install Dspace RUN git clone https://github.com/commul/clarin-dspace.git -b clarin /opt/repository/sources/dspace WORKDIR /opt/repository/sources/dspace/utilities/project_helpers RUN ./setup.sh /opt/repository/workspace COPY commul-customization/variable.makefile /opt/repository/workspace/config/variable.makefile # copy over configs and startup scripts COPY commul-customization/start_stack.sh /opt/repository/workspace/scripts/ COPY commul-customization/stop_stack.sh /opt/repository/workspace/scripts/ COPY commul-customization/local.properties /opt/repository/workspace/sources/ RUN chmod u+x /opt/repository/workspace/scripts/*_stack.sh # install libs WORKDIR /opt/repository/workspace/scripts RUN make install_libs # copy over config files COPY commul-customization/aai_config.js /tmp/ COPY commul-customization/aai.js /opt/repository/sources/lindat-aai-discovery/ WORKDIR /opt/repository/sources/lindat-aai-discovery/ # this line only is necessary until https://github.com/ufal/lindat-aai-discovery/issues/6 is resolved RUN perl -pi -e 's/http/https/' /opt/repository/sources/lindat-aai-discovery/Makefile RUN touch /opt/repository/sources/lindat-aai-discovery/aai.js RUN make aai.min.js # convenience setting of workdir WORKDIR /opt/repository/workspace/scripts CMD tail -f /opt/repository/sources/dspace/dspace-api/src/test/data/dspaceFolder/log/dspace.log