-
Notifications
You must be signed in to change notification settings - Fork 2
/
Dockerfile
54 lines (36 loc) · 1.45 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
FROM continuumio/miniconda3 AS nmrkit-ms
ENV PYTHON_VERSION=3.10
ENV OPENBABEL_VERSION=v3.1
ARG RELEASE_VERSION
ENV RELEASE_VERSION=${RELEASE_VERSION}
# Install runtime dependencies
RUN apt-get update && \
apt-get install -y software-properties-common && \
apt-get update -y && \
apt-get install -y openjdk-11-jre && \
apt-get install -y curl && \
conda update -n base -c defaults conda
RUN apt-get update && apt-get -y install docker.io
RUN conda install -c conda-forge python>=PYTHON_VERSION
RUN conda install -c conda-forge openbabel>=OPENBABEL_VERSION
RUN pip3 install rdkit
RUN python3 -m pip install -U pip
ENV JAVA_HOME /usr/lib/jvm/java-11-openjdk-amd64/
RUN export JAVA_HOME
RUN git clone "https://github.com/rinikerlab/lightweight-registration.git" lwreg
RUN chmod +x lwreg
RUN pip3 install --editable ./lwreg/.
WORKDIR /code
COPY ./requirements.txt /code/requirements.txt
COPY ./alembic.ini /code/alembic.ini
RUN pip3 install --upgrade setuptools pip && \
apt-get update && apt-get install -y git
RUN pip3 install --no-cache-dir -r /code/requirements.txt
RUN python3 -m pip uninstall -y uvicorn
RUN python3 -m pip install uvicorn[standard]
COPY ./app /code/app
RUN curl -sL https://deb.nodesource.com/setup_current.x | bash -
RUN apt-get install -y nodejs
RUN npm install -g npm@latest
RUN npm install -g /code/app/scripts/nmr-cli
CMD ["uvicorn", "app.main:app", "--host", "0.0.0.0", "--port", "80", "--workers", "4", "--reload"]