-
Notifications
You must be signed in to change notification settings - Fork 0
/
Dockerfile
43 lines (36 loc) · 898 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
34
35
36
37
38
39
40
41
42
43
# Remember to run the docker image in privileged mode for isolate to work!
# Use the official Ubuntu LTS image (focal)
FROM ubuntu:focal AS builder
# Install Python 3, C++ (via g++), and the JDK
RUN apt-get update && apt-get install -y \
python3 \
python3-pip \
g++ \
openjdk-14-jdk-headless
# Install other dependencies
# libcap2 is required for isolate
RUN apt-get install -y \
time \
redis \
libcap2
# Install production dependencies for Python 3
RUN pip3 install \
Flask \
gunicorn \
psutil \
rq \
pyyaml \
pylint \
requests \
markdown \
python-markdown-math \
flask-cors \
pytz
# Copy local code to the container image
ENV APP_HOME /app
WORKDIR $APP_HOME
COPY . ./
# Move isolate config file to correct location
RUN mv misc/isolate.cf /usr/local/etc/isolate
# Run the startup script
ENTRYPOINT ["./misc/start.sh"]