This repository has been archived by the owner on Jun 19, 2019. It is now read-only.
forked from hdzierz/docker-webapollo2
-
Notifications
You must be signed in to change notification settings - Fork 12
/
Copy pathDockerfile
61 lines (42 loc) · 2.03 KB
/
Dockerfile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
# WebApollo
# VERSION 2.1.X
FROM tomcat:9-jdk8
MAINTAINER Nathan Dunn <[email protected]>
ENV DEBIAN_FRONTEND noninteractive
RUN apt-get -qq update --fix-missing && \
apt-get --no-install-recommends -y install \
git build-essential maven libpq-dev postgresql-common openjdk-8-jdk wget \
postgresql postgresql-client xmlstarlet netcat libpng-dev \
zlib1g-dev libexpat1-dev ant curl ssl-cert zip unzip
RUN curl -sL https://deb.nodesource.com/setup_8.x | bash -
RUN apt-get -qq update --fix-missing && \
apt-get --no-install-recommends -y install nodejs && \
apt-get autoremove -y && apt-get clean && rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/*
RUN npm i -g yarn
RUN cp /usr/lib/jvm/java-8-openjdk-amd64/lib/tools.jar /usr/lib/jvm/java-8-openjdk-amd64/jre/lib/ext/tools.jar && \
useradd -ms /bin/bash -d /apollo apollo
ENV WEBAPOLLO_VERSION 6b7f7b76792a9e111cd31257aef9c4789a8b097e
RUN curl -L https://github.com/GMOD/Apollo/archive/${WEBAPOLLO_VERSION}.tar.gz | tar xzf - --strip-components=1 -C /apollo
# install grails
COPY build.sh /bin/build.sh
ADD apollo-config.groovy /apollo/apollo-config.groovy
RUN chown -R apollo:apollo /apollo
RUN curl -s "http://hgdownload.soe.ucsc.edu/admin/exe/linux.x86_64/blat/blat" -o /usr/local/bin/blat
RUN chmod +x /usr/local/bin/blat
USER apollo
RUN curl -s get.sdkman.io | bash
RUN /bin/bash -c "source $HOME/.sdkman/bin/sdkman-init.sh && yes | sdk install grails 2.5.5"
RUN /bin/bash -c "source $HOME/.sdkman/bin/sdkman-init.sh && yes | sdk install gradle 3.2.1"
RUN /bin/bash -c "source $HOME/.profile && source $HOME/.sdkman/bin/sdkman-init.sh && /bin/bash /bin/build.sh"
USER root
ENV CATALINA_HOME=/usr/local/tomcat
RUN rm -rf ${CATALINA_HOME}/webapps/* && \
cp /apollo/apollo*.war ${CATALINA_HOME}/apollo.war
ENV CONTEXT_PATH ROOT
# Download chado schema
RUN wget --quiet https://github.com/erasche/chado-schema-builder/releases/download/1.31-jenkins97/chado-1.31.sql.gz -O /chado.sql.gz && \
gunzip /chado.sql.gz
ADD createenv.sh /createenv.sh
CMD "/createenv.sh"
ADD launch.sh /launch.sh
CMD "/launch.sh"