Skip to content

Commit

Permalink
schutzbot: use s3cmd from repositories
Browse files Browse the repository at this point in the history
s3cmd from pip doesn't work with Python 3.9. Fortunately, s3cmd in Fedora has
a downstream patch to fix it.

See rhbz#1884607 and s3tools/s3cmd#1137
  • Loading branch information
ondrejbudai authored and msehnout committed Oct 14, 2020
1 parent a67baf5 commit 1a69a89
Showing 1 changed file with 2 additions and 8 deletions.
10 changes: 2 additions & 8 deletions schutzbot/mockbuild.sh
Expand Up @@ -10,7 +10,7 @@ function greenprint {
source /etc/os-release
ARCH=$(uname -m)

# Mock is only available in EPEL for RHEL.
# Mock and s3cmd is only available in EPEL for RHEL.
if [[ $ID == rhel ]] && ! rpm -q epel-release; then
greenprint "📦 Setting up EPEL repository"
curl -Ls --retry 5 --output /tmp/epel.rpm \
Expand All @@ -27,13 +27,7 @@ fi

# Install requirements for building RPMs in mock.
greenprint "📦 Installing mock requirements"
sudo dnf -y install createrepo_c make mock python3-pip rpm-build

# Install s3cmd if it is not present.
if ! s3cmd --version > /dev/null 2>&1; then
greenprint "📦 Installing s3cmd"
sudo pip3 -q install s3cmd
fi
sudo dnf -y install createrepo_c make mock rpm-build s3cmd

# Jenkins sets a workspace variable as the root of its working directory.
WORKSPACE=${WORKSPACE:-$(pwd)}
Expand Down

0 comments on commit 1a69a89

Please sign in to comment.