-
Notifications
You must be signed in to change notification settings - Fork 36
Expand file tree
/
Copy pathDockerfile
More file actions
44 lines (27 loc) · 1.02 KB
/
Dockerfile
File metadata and controls
44 lines (27 loc) · 1.02 KB
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
FROM node:25-bookworm-slim AS build-frontend
RUN mkdir /opt/conditional
WORKDIR /opt/conditional
RUN apt-get -yq update && \
apt-get -yq install curl git
COPY package.json package-lock.json /opt/conditional/
RUN npm ci
COPY webpack.config.js /opt/conditional
COPY frontend /opt/conditional/frontend
RUN npm run webpack
FROM docker.io/python:3.12-slim-bookworm
MAINTAINER Computer Science House <webmaster@csh.rit.edu>
RUN mkdir /opt/conditional
COPY requirements.txt /opt/conditional
WORKDIR /opt/conditional
RUN apt-get -yq update && \
apt-get -yq install libsasl2-dev libldap2-dev libldap-common libssl-dev gcc g++ make && \
pip install -r requirements.txt && \
apt-get -yq clean all
ARG PORT=8080
ENV PORT=${PORT}
EXPOSE ${PORT}
COPY conditional /opt/conditional/conditional
COPY *.py package.json /opt/conditional
COPY --from=build-frontend /opt/conditional/conditional/static /opt/conditional/conditional/static
RUN ln -sf /usr/share/zoneinfo/America/New_York /etc/localtime
CMD ["sh", "-c", "gunicorn"]