-
Piotr Gawron authoredPiotr Gawron authored
Code owners
Assign users and groups as approvers for specific file changes. Learn more.
Dockerfile 2.38 KiB
#Docker description file for minerva framework.
FROM debian:jessie
MAINTAINER Piotr Gawron <piotr.gawron@uni.lu>
#setup non interactive install in apt-get
ENV DEBIAN_FRONTEND noninteractive
#installation of needed packages
#Some basic tools (optionally)
RUN apt-get update
RUN apt-get install -y apt-utils w3m
RUN apt-get install -y telnet
RUN apt-get install -y vim
RUN apt-get install -y procps
RUN apt-get install -y wget
#Minerva repo is via ssl
RUN apt-get install -y apt-transport-https
RUN apt-get install -y supervisor
RUN mkdir -p /var/log/supervisor
#Java 8 repository
RUN echo "deb http://ppa.launchpad.net/webupd8team/java/ubuntu trusty main" | tee /etc/apt/sources.list.d/webupd8team-java.list
RUN echo "deb-src http://ppa.launchpad.net/webupd8team/java/ubuntu trusty main" | tee -a /etc/apt/sources.list.d/webupd8team-java.list
RUN apt-key adv --keyserver hkp://keyserver.ubuntu.com:80 --recv-keys EEA14886
RUN apt-get update
#Make sure that installer won't ask for accepting license
RUN echo debconf shared/accepted-oracle-license-v1-1 select true | debconf-set-selections
#Minerva uni.lu repository
RUN echo "deb http://repo-r3lab.uni.lu/debian/ stable main" | tee /etc/apt/sources.list.d/r3lab-uni.list
RUN apt-key adv --keyserver hkp://keyserver.ubuntu.com:80 --recv-keys 0xcb185f4e31872412
RUN apt-get update
#install dependencies separatelly (usefull when we change something - then we don't have to do everything from scratch)
RUN apt-get install -y tomcat7 && /etc/init.d/tomcat7 stop
RUN apt-get install -y postgresql
RUN apt-get install -y oracle-java8-set-default
ADD policy-rc.d /tmp/policy-rc.d
RUN apt-get update
RUN sed -i "/JAVA_OPTS=\"-Djava.awt.headless=true -Xmx128m -XX:+UseConcMarkSweepGC\"/c\JAVA_OPTS=\"-Djava.awt.headless=true -Xmx3096m -XX:+UseConcMarkSweepGC\"" /etc/default/tomcat7
#when we install minerva allow to start services, so everything can be installed properly
#but we need to disable tomcat7 because tomcat7 requires SYS_PTRACE and we cannot start it:
#take a look here:
#http://stackoverflow.com/questions/29683231/tomcat7-fail-to-start-inside-ubuntu-docker-container
RUN mv /usr/sbin/policy-rc.d /usr/sbin/policy-rc.d.backup && \
mv /tmp/policy-rc.d /usr/sbin/policy-rc.d && \
apt-get install -y minerva && \
mv /usr/sbin/policy-rc.d.backup /usr/sbin/policy-rc.d
EXPOSE 8080
ADD supervisord.conf /etc/supervisor/conf.d/supervisord.conf
ADD .bashrc /root/