fix: linux builds (#3485)

This commit is contained in:
cyan
2026-08-07 22:10:27 +02:00
committed by GitHub
parent b60b5a59f7
commit 43cd125942
15 changed files with 288 additions and 71 deletions
+20
View File
@@ -0,0 +1,20 @@
ARG BASE_IMAGE
FROM --platform=linux/amd64 ${BASE_IMAGE} AS build
COPY scripts/prepare_torch.sh /w/scripts/prepare_torch.sh
COPY scripts/linux/build_torch.sh /w/scripts/linux/build_torch.sh
ARG UID=10001
ARG GID=10001
ARG USER=builder
RUN groupadd -g "$GID" "$USER" && \
useradd -m -u "$UID" -g "$GID" -s /bin/bash "$USER"
RUN sudo chown $UID:$GID -R /w /root
USER builder
RUN /w/scripts/prepare_torch.sh
FROM --platform=linux/amd64 alpine
COPY --from=build /w /w