add gitea workflow

This commit is contained in:
konjacpotato
2025-11-12 20:53:23 +08:00
parent 8c1a740f0b
commit 4fb7c9fc68
31 changed files with 218 additions and 0 deletions

19
Dockerfile Normal file
View File

@ -0,0 +1,19 @@
# 使用官方轻量级 Python 基础镜像
FROM python:3.12-slim
# 设置工作目录(容器内路径)
WORKDIR /app
# 将项目文件复制到容器中
COPY . /app
# (可选)如果你有 requirements.txt则先复制并安装依赖
RUN if [ -f requirements.txt ]; then \
pip install --no-cache-dir -r requirements.txt -i https://mirrors.aliyun.com/pypi/simple/; \
fi
# 设置环境变量(防止 Python 缓存文件)
ENV PYTHONUNBUFFERED=1
# 启动命令
CMD ["python", "peter.py"]