Repository navigation
Expand file tree
/
Copy pathDockerfile.ytserver
More file actions
48 lines (35 loc) · 1.53 KB
/
Copy pathDockerfile.ytserver
File metadata and controls
48 lines (35 loc) · 1.53 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
44
45
46
47
48
# Copyright 2025-2026 deltaaa00
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
FROM rust:1.83-slim AS rust-builder
WORKDIR /build
RUN apt-get update && apt-get install -y python3 python3-pip && rm -rf /var/lib/apt/lists/* \
&& pip3 install --no-cache-dir --break-system-packages "maturin>=1.7,<2.0"
COPY automap_rs/ ./automap_rs/
RUN cd automap_rs && maturin build --release --interpreter python3 --out /wheels
FROM python:3.12-slim
RUN apt-get update && apt-get install -y \
ffmpeg \
curl \
unzip \
&& curl -fsSL https://deno.land/install.sh | DENO_INSTALL=/usr/local sh \
&& rm -rf /var/lib/apt/lists/*
WORKDIR /app
COPY requirements.txt .
RUN pip install --no-cache-dir -r requirements.txt
COPY --from=rust-builder /wheels/*.whl /tmp/
RUN pip install --no-cache-dir /tmp/*.whl && rm -f /tmp/*.whl
COPY yt-dlp_serv.py sticker_themes.py extra_stickers.py server_runtime.py render_progress.py video_text.py video_stickers.py video_render.py ./
COPY resources/fonts/ resources/fonts/
EXPOSE 8080
CMD ["python", "yt-dlp_serv.py"]