-
Notifications
You must be signed in to change notification settings - Fork 3.9k
Expand file tree
/
Copy pathDockerfile
More file actions
34 lines (24 loc) · 893 Bytes
/
Copy pathDockerfile
File metadata and controls
34 lines (24 loc) · 893 Bytes
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
FROM alpine:3.20
# Install runtime dependencies
RUN apk add --no-cache python3 py3-pip nginx curl unzip jq bash tzdata
# Install build dependencies needed for Pillow and psutil
RUN apk add --no-cache --virtual .build-deps \
gcc musl-dev python3-dev zlib-dev jpeg-dev freetype-dev linux-headers
WORKDIR /app
COPY requirements.txt .
# Install Python dependencies
RUN pip3 install --no-cache-dir --break-system-packages -r requirements.txt \
&& apk del .build-deps
# Install Xray-core
RUN curl -fsSL -o xray.zip "https://github.com/XTLS/Xray-core/releases/latest/download/Xray-linux-64.zip" && \
unzip xray.zip -d /usr/local/bin/ && \
chmod +x /usr/local/bin/xray && \
rm xray.zip
# Copy application files
COPY . /app
# Copy nginx config
COPY nginx.conf /etc/nginx/nginx.conf
# Entrypoint setup
RUN chmod +x /app/entrypoint.sh
EXPOSE 8000
CMD ["/app/entrypoint.sh"]