-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathDockerfile
33 lines (26 loc) · 1011 Bytes
/
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
FROM python:3.6.8
EXPOSE 80
ENV MYDIR /tfdnapredictions
RUN curl -sL https://deb.nodesource.com/setup_10.x | bash -
RUN apt-get install -y nodejs
# Install bigBedToBed
ADD ./third_party/linux.x86_64/bigBedToBed /usr/local/bin/bigBedToBed
RUN ["chmod", "755", "/usr/local/bin/bigBedToBed"]
# Install global dependencies
RUN ["pip", "install", "gunicorn"]
# Install project dependencies - dependency files are added independently so that
# changes to application source code don't trigger a cache invalidation at this step
WORKDIR ${MYDIR}
ADD requirements.txt ${MYDIR}/
RUN ["pip", "install", "-r", "requirements.txt"]
# install portal requirements
WORKDIR ${MYDIR}/portal
ADD portal/package.json ${MYDIR}/portal/package.json
RUN npm install
RUN npm install --only=dev
# Now add the rest of the application source and run webpack
ADD . ${MYDIR}
CMD bash
RUN ./node_modules/.bin/webpack -p
WORKDIR ${MYDIR}
CMD ["gunicorn", "--bind", "0.0.0.0:80", "--timeout", "180", "--log-level=debug", "webserver:app"]