File size: 616 Bytes
48d88ef
a1fe04b
 
48d88ef
 
 
 
a1fe04b
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
48d88ef
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
# Use an official Python runtime as a parent image
FROM python:3.9

# Install Java
RUN apt-get update && \
    apt-get install -y default-jdk

# Install OpenGL dependencies and Xvfb
RUN apt-get update && \
    apt-get install -y libgl1-mesa-glx libgl1-mesa-dev xvfb

# Set the working directory in the container
WORKDIR /app

# Copy the app.py script to the working directory
COPY app.py .

# Install the required Python dependencies
RUN pip install pyglet arcade pygame

# Set the display environment variable
ENV DISPLAY=:99

# Run Xvfb and the app.py script when the container starts
CMD Xvfb :99 & python app.py