Skip to content

Commit

Permalink
Install Python deps (#423)
Browse files Browse the repository at this point in the history
* add dependencies to fedora images

* add dependencies to debian images

* add dependencies to rhel images

* use correct context folder

* fix up rawhide
  • Loading branch information
justice-adams-apple authored Oct 11, 2024
1 parent 1c187af commit c20c072
Show file tree
Hide file tree
Showing 12 changed files with 50 additions and 2 deletions.
2 changes: 1 addition & 1 deletion ci_test.py
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@ def main():
# Make sure everything is relative
dockerfile = os.path.relpath(os.path.realpath(dockerfile), root_dir)

docker_dir, docker_name = os.path.split(dockerfile)
docker_dir = "."

print("Testing {}".format(dockerfile))
sys.stdout.flush()
Expand Down
4 changes: 4 additions & 0 deletions swift-ci/main/debian/10/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@ RUN apt-get -y update && apt-get -y --no-install-recommends install \
python \
python-six \
python2-dev \
python3-pip \
python3-six \
python3-distutils \
rsync \
Expand All @@ -33,6 +34,9 @@ RUN apt-get -y update && apt-get -y --no-install-recommends install \
uuid-dev \
ca-certificates

COPY swift-ci/dependencies/requirements.txt /dependencies/
RUN pip3 install -r /dependencies/requirements.txt

USER build-user

WORKDIR /home/build-user
4 changes: 4 additions & 0 deletions swift-ci/main/debian/11/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -25,13 +25,17 @@ RUN apt-get -y update && apt-get -y install \
python2-dev \
python3-six \
python3-distutils \
python3-pip \
rsync \
swig \
systemtap-sdt-dev \
tzdata \
unzip \
uuid-dev

COPY swift-ci/dependencies/requirements.txt /dependencies/
RUN pip3 install -r /dependencies/requirements.txt

USER build-user

WORKDIR /home/build-user
4 changes: 4 additions & 0 deletions swift-ci/main/debian/12/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@ RUN apt-get -y update && apt-get -y install \
ninja-build \
pkg-config \
python3-distutils \
python3-pip \
python3-pkg-resources \
python3-psutil \
rsync \
Expand All @@ -46,6 +47,9 @@ ENV SWIFT_PLATFORM=$SWIFT_PLATFORM \
SWIFT_WEBROOT=$SWIFT_WEBROOT \
SWIFT_PREFIX=$SWIFT_PREFIX

COPY swift-ci/dependencies/requirements.txt /dependencies/
RUN pip3 install -r /dependencies/requirements.txt --break-system-packages

RUN set -e; \
ARCH_NAME="$(dpkg --print-architecture)"; \
url=; \
Expand Down
9 changes: 9 additions & 0 deletions swift-ci/main/debian/9/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,9 @@ RUN groupadd -g 998 build-user && \

ENV DEBIAN_FRONTEND="noninteractive"

RUN sed -i s/deb.debian.org/archive.debian.org/g /etc/apt/sources.list
RUN sed -i s/security.debian.org/archive.debian.org/g /etc/apt/sources.list
RUN sed -i s/stretch-updates/stretch/g /etc/apt/sources.list
RUN apt-get update

RUN apt-get --no-install-recommends -y install \
Expand All @@ -22,6 +25,9 @@ RUN apt-get --no-install-recommends -y install \
ninja-build \
pkg-config \
python \
python3-setuptools \
python3-dev \
python3-pip \
python-six \
rsync \
swig \
Expand All @@ -31,6 +37,9 @@ RUN apt-get --no-install-recommends -y install \
ca-certificates \
uuid-dev

COPY swift-ci/dependencies/requirements.txt /dependencies/
RUN pip3 install -r /dependencies/requirements.txt

USER build-user

WORKDIR /home/build-user
4 changes: 4 additions & 0 deletions swift-ci/main/fedora/31/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -20,12 +20,16 @@ RUN dnf -y update && dnf install -y \
python-unversioned-command \
python27 \
python3 \
python3-pip \
python3-devel \
python3-distro \
python3-six \
rsync \
swig

COPY swift-ci/dependencies/requirements.txt /dependencies/
RUN pip3 install -r /dependencies/requirements.txt

USER build-user

WORKDIR /home/build-user
Expand Down
4 changes: 4 additions & 0 deletions swift-ci/main/fedora/32/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -20,12 +20,16 @@ RUN dnf -y update && dnf install -y \
python-unversioned-command \
python27 \
python3 \
python3-pip \
python3-devel \
python3-distro \
python3-six \
rsync \
swig

COPY swift-ci/dependencies/requirements.txt /dependencies/
RUN pip3 install -r /dependencies/requirements.txt

USER build-user

WORKDIR /home/build-user
Expand Down
4 changes: 4 additions & 0 deletions swift-ci/main/fedora/39/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ RUN yum install -y \
libuuid-devel \
libxml2-devel \
python3 \
python3-pip \
python3-devel \
python3-distro \
python3-setuptools \
Expand Down Expand Up @@ -40,6 +41,9 @@ ENV SWIFT_PLATFORM=$SWIFT_PLATFORM \
SWIFT_WEBROOT=$SWIFT_WEBROOT \
SWIFT_PREFIX=$SWIFT_PREFIX

COPY swift-ci/dependencies/requirements.txt /dependencies/
RUN pip3 install -r /dependencies/requirements.txt

RUN set -e; \
ARCH_NAME="$(rpm --eval '%{_arch}')"; \
url=; \
Expand Down
4 changes: 4 additions & 0 deletions swift-ci/main/fedora/40/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ RUN yum install -y \
libuuid-devel \
libxml2-devel \
python3 \
python3-pip \
python3-devel \
python3-distro \
python3-setuptools \
Expand All @@ -26,6 +27,9 @@ RUN yum install -y \
unzip \
diffutils

COPY swift-ci/dependencies/requirements.txt /dependencies/
RUN pip3 install -r /dependencies/requirements.txt

USER build-user

WORKDIR /home/build-user
5 changes: 4 additions & 1 deletion swift-ci/main/fedora/rawhide/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -18,14 +18,17 @@ RUN dnf -y update && dnf install -y \
make \
ninja-build \
python-unversioned-command \
python27 \
python3 \
python3-pip \
python3-devel \
python3-distro \
python3-six \
rsync \
swig

COPY swift-ci/dependencies/requirements.txt /dependencies/
RUN pip3 install -r /dependencies/requirements.txt

USER build-user

WORKDIR /home/build-user
Expand Down
4 changes: 4 additions & 0 deletions swift-ci/main/rhel-ubi/8/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -15,11 +15,15 @@ RUN yum install -y \
libxml2-devel \
ncurses-devel \
python3-devel \
python3-pip \
rsync \
sqlite-devel \
unzip \
zip

COPY swift-ci/dependencies/requirements.txt /dependencies/
RUN pip3 install -r /dependencies/requirements.txt

USER build-user

WORKDIR /home/build-user
4 changes: 4 additions & 0 deletions swift-ci/main/rhel-ubi/9/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@ RUN yum install -y \
libxml2-devel \
ncurses-devel \
python3-devel \
python3-pip \
rsync \
sqlite-devel \
unzip \
Expand All @@ -34,6 +35,9 @@ ENV SWIFT_PLATFORM=$SWIFT_PLATFORM \
SWIFT_WEBROOT=$SWIFT_WEBROOT \
SWIFT_PREFIX=$SWIFT_PREFIX

COPY swift-ci/dependencies/requirements.txt /dependencies/
RUN pip3 install -r /dependencies/requirements.txt

RUN set -e; \
ARCH_NAME="$(rpm --eval '%{_arch}')"; \
url=; \
Expand Down

0 comments on commit c20c072

Please sign in to comment.