fix: 禁用 ustreamer 编译步骤的 Docker 构建缓存

- 在 Dockerfile-stage-0 中添加 CACHEBUST 参数强制重新编译 ustreamer
- GitHub Actions 构建时传递时间戳作为 CACHEBUST 值
- 确保 ustreamer 每次构建都使用最新源码
This commit is contained in:
mofeng-git 2025-08-22 23:04:50 +08:00
parent 04b13b1215
commit d411affca4
2 changed files with 5 additions and 1 deletions

View File

@ -103,6 +103,8 @@ jobs:
provenance: false
sbom: false
allow: security.insecure
build-args: |
CACHEBUST=$(date +%s)
build-main:
runs-on: ubuntu-22.04

View File

@ -132,7 +132,9 @@ RUN git clone --depth=1 https://gitlab.freedesktop.org/libnice/libnice /tmp/libn
&& rm -rf /tmp/janus-gateway
# 编译 ustreamer
RUN sed --in-place --expression 's|^#include "refcount.h"$|#include "../refcount.h"|g' /usr/include/janus/plugins/plugin.h \
ARG CACHEBUST=1
RUN echo "Cache bust: $CACHEBUST" \
&& sed --in-place --expression 's|^#include "refcount.h"$|#include "../refcount.h"|g' /usr/include/janus/plugins/plugin.h \
&& git clone --depth=1 https://github.com/mofeng-git/ustreamer /tmp/ustreamer \
&& make -j WITH_PYTHON=1 WITH_JANUS=1 WITH_FFMPEG=1 -C /tmp/ustreamer \
&& /tmp/ustreamer/ustreamer -v \