Skip to content

Commit ea6c30d

Browse files
build script comment manylinux check
1 parent 04aef69 commit ea6c30d

File tree

1 file changed

+23
-15
lines changed

1 file changed

+23
-15
lines changed

.github/scripts/s390x-ci/self-hosted-builder/actions-runner.Dockerfile

Lines changed: 23 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
# Stage 1: Temporary image for amd64 dependencies
2-
FROM docker.io/amd64/ubuntu:22.04 as ld-prefix
2+
FROM docker.io/amd64/ubuntu:22.04 AS ld-prefix
33
ENV DEBIAN_FRONTEND=noninteractive
44

55
# Install amd64-specific dependencies
@@ -9,11 +9,19 @@ RUN apt-get update && apt-get -y install \
99
libssl3
1010

1111
# Stage 2: Main image for ppc64le Ubuntu
12-
FROM --platform=linux/ppc64le ubuntu:22.04
12+
FROM ubuntu:22.04
1313

1414
# Set non-interactive mode for apt
1515
ENV DEBIAN_FRONTEND=noninteractive
1616

17+
# Fix sources to point to ports.ubuntu.com for ppc64le
18+
RUN sed -i 's|archive.ubuntu.com|ports.ubuntu.com|g' /etc/apt/sources.list && \
19+
sed -i 's|security.ubuntu.com|ports.ubuntu.com|g' /etc/apt/sources.list
20+
21+
# Update and clean apt
22+
RUN apt-get update -o Acquire::Retries=3 && \
23+
apt-get clean && rm -rf /var/lib/apt/lists/*
24+
1725
# Install dependencies for building and testing PyTorch
1826
RUN apt-get update && apt-get -y install --no-install-recommends \
1927
build-essential \
@@ -42,31 +50,31 @@ RUN apt-get update && apt-get -y install --no-install-recommends \
4250
ca-certificates \
4351
&& apt-get clean && rm -rf /var/lib/apt/lists/*
4452

45-
# Copy amd64 dependencies from the ld-prefix stage
46-
COPY --from=ld-prefix / /usr/x86_64-linux-gnu/
47-
RUN ln -fs ../lib/x86_64-linux-gnu/ld-linux-x86-64.so.2 /usr/x86_64-linux-gnu/lib64/
48-
RUN ln -fs /etc/resolv.conf /usr/x86_64-linux-gnu/etc/
49-
ENV QEMU_LD_PREFIX=/usr/x86_64-linux-gnu
50-
51-
# Copy custom scripts
52-
COPY fs/ /
53-
RUN chmod +x /usr/bin/actions-runner /usr/bin/entrypoint
54-
55-
# Install Docker Engine for ppc64le
56-
RUN apt-get update && apt-get install -y \
53+
# Fix: Add Docker Engine repository correctly for ppc64le
54+
RUN apt-get update && apt-get install -y --no-install-recommends \
5755
apt-transport-https \
5856
ca-certificates \
5957
curl \
6058
gnupg-agent \
6159
software-properties-common \
6260
&& curl -fsSL https://download.docker.com/linux/ubuntu/gpg | apt-key add - \
6361
&& echo "deb [arch=ppc64el] https://download.docker.com/linux/ubuntu $(lsb_release -cs) stable" > /etc/apt/sources.list.d/docker.list \
64-
&& apt-get update && apt-get install -y \
62+
&& apt-get update -o Acquire::Retries=3 && apt-get install -y \
6563
docker-ce \
6664
docker-ce-cli \
6765
containerd.io \
6866
&& apt-get clean && rm -rf /var/lib/apt/lists/*
6967

68+
# Copy amd64 dependencies from the ld-prefix stage
69+
COPY --from=ld-prefix / /usr/x86_64-linux-gnu/
70+
RUN ln -fs ../lib/x86_64-linux-gnu/ld-linux-x86-64.so.2 /usr/x86_64-linux-gnu/lib64/
71+
RUN ln -fs /etc/resolv.conf /usr/x86_64-linux-gnu/etc/
72+
ENV QEMU_LD_PREFIX=/usr/x86_64-linux-gnu
73+
74+
# Copy custom scripts
75+
COPY fs/ /
76+
RUN chmod +x /usr/bin/actions-runner /usr/bin/entrypoint
77+
7078
# Configure GitHub Actions Runner for amd64
7179
RUN useradd -m actions-runner
7280
USER actions-runner

0 commit comments

Comments
 (0)