diff --git a/.github/workflows/pytest.yml b/.github/workflows/pytest.yml index 9f1ebe9ade..b528fcfd51 100644 --- a/.github/workflows/pytest.yml +++ b/.github/workflows/pytest.yml @@ -21,6 +21,28 @@ jobs: image: ${{ matrix.image }} steps: + - name: "Enable EPEL repository" + run: | + yum -y install epel-release + + - name: "Install core packages" + run: | + yum install -y \ + git-core gcc make python python-devel python-setuptools python-pip + + # We need to initiate the repository manually because Actions fallback + # to REST API with Git < 2.18; CentOS 7/RHEL 7 have 1.8. + # See https://github.com/actions/checkout#checkout-v3 + # See https://github.com/actions/checkout/issues/766 + - name: "Initiate new git repository" + run: | + git config --global user.email "chainsaw@redhat.com" + git config --global user.name "RHSM for RHEL 7 at GitHub Actions" + git init + git add . + git commit -m "Detached commit" + git config --global --add safe.directory '*' + - name: "Checkout repository" uses: actions/checkout@v3 diff --git a/scripts/container-pre-test.sh b/scripts/container-pre-test.sh index adf16899d3..f0c7c0e867 100644 --- a/scripts/container-pre-test.sh +++ b/scripts/container-pre-test.sh @@ -1,11 +1,5 @@ #!/bin/bash -yum install -y epel-release - -# Install essential packages -yum install -y \ - git gcc make python python-devel python-setuptools python-pip - # Install system, build and runtime packages yum install -y \ gtk3-devel python-ethtool \