mirror of
https://github.com/0-8-4/miui-auto-tasks.git
synced 2025-01-30 15:08:53 +00:00
e2b4643b4f
* 🔧 自动更新requirements * feat: 更改geetest验证方式 * 🔧 自动更新requirements * Update Dockerfile * Update requirements.txt * 🔧 自动更新requirements * Update requirements.txt * Update Dockerfile * Update docker-image.yml * Update Dockerfile * 🔧 自动更新requirements * feat: geetest添加自定义返回参数 * feat: geetest添加自定义返回参数 * Update pyproject.toml * Update Dockerfile * fix: 修复docker编译失败,jsonpath为空时报错 * chore: config添加默认值 * ci: 自动更改版本号 * ci: 自动更新版本号 * 🔧 自动更新requirements * fix: 补全dockerfile缺失 * ci: 拉取本地仓库 * ci: 添加其他docker 设备 * ci: 改用docker更改版本号 --------- Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
22 lines
619 B
Docker
22 lines
619 B
Docker
FROM python:alpine
|
|
|
|
RUN apk add --no-cache gcc g++ musl-dev python3-dev libffi-dev rust openssl-dev cargo pkgconfig
|
|
|
|
RUN pip install --no-cache-dir pdm
|
|
|
|
WORKDIR /srv
|
|
|
|
COPY ./utils ./utils
|
|
|
|
RUN echo "VERSION='$(git describe --tags --abbrev=0)'" > ./utils/__version__.py
|
|
|
|
COPY ./pyproject.toml ./pdm.lock ./miuitask.py ./docker_start.sh ./
|
|
|
|
RUN pdm install --prod && \
|
|
echo '0 4 * * * /bin/sh -c "sleep $((RANDOM % 1800 + 1)); cd /srv && pdm run /srv/miuitask.py"' > /var/spool/cron/crontabs/root && \
|
|
chmod +x docker_start.sh
|
|
|
|
VOLUME ["/srv/data", "/srv/logs"]
|
|
|
|
CMD ["/srv/docker_start.sh"]
|