@@ -216,6 +216,13 @@ jobs:
216216 centos :
217217 - 7 # GCC 4.8
218218 - 8
219+ include :
220+ - centos : 7
221+ python_pkg : rh-python38-python-pip rh-python38-python-devel
222+ enable_repo : --enablerepo=centos-sclo-rh
223+ - centos : 8
224+ python_pkg : python38-devel
225+
219226
220227 name : " Python 3 • CentOS ${{ matrix.centos }} • x64"
221228 container : " centos:${{ matrix.centos }}"
@@ -238,12 +245,18 @@ jobs:
238245 sed -i 's/mirrorlist/#mirrorlist/g' /etc/yum.repos.d/CentOS-*
239246 sed -i 's|#baseurl=http://mirror.centos.org|baseurl=http://vault.centos.org|g' /etc/yum.repos.d/CentOS-*
240247
241- - name : Add Python 3 and other dependencies
242- run : yum update -y && yum install -y python3-devel gcc-c++ make
248+ - name : Update YUM/DNF
249+ run : yum update -y
243250
244- - name : Setup Endpoint repository (CentOS 7 only )
251+ - name : Enable extra repositories && modify PATH (CentOS 7)
245252 if : matrix.centos == 7
246- run : yum -y install https://packages.endpointdev.com/rhel/7/os/x86_64/endpoint-repo.x86_64.rpm
253+ run : |
254+ yum install -y centos-release-scl-rh
255+ yum -y install https://packages.endpointdev.com/rhel/7/os/x86_64/endpoint-repo.x86_64.rpm
256+ echo '/opt/rh/rh-python38/root/usr/bin' >> $GITHUB_PATH
257+
258+ - name : Add Python 3 and other dependencies
259+ run : yum install -y ${{ matrix.enable_repo }} ${{ matrix.python_pkg }} gcc-c++ make
247260
248261 - name : Install Git > 2.18
249262 run : |
@@ -262,14 +275,9 @@ jobs:
262275 uses : actions/cache@v3
263276 with :
264277 path : ~/.cache/pip
265- key : >
266- ${{ runner.os }}-centos${{ matrix.centos }}-pip-
267- ${{ hashFiles('setup.cfg', 'pyproject.toml', 'requirements_tests.txt') }}
278+ key : ${{ runner.os }}-centos${{ matrix.centos }}-pip-${{ hashFiles('**/setup.cfg', '**/pyproject.toml') }}
268279 restore-keys : ${{ runner.os }}-centos-pip-
269280
270- - name : Update pip
271- run : python3 -m pip install --upgrade pip
272-
273281 - name : Install dependencies
274282 run : |
275283 python3 -m pip install -U pip setuptools wheel
@@ -293,16 +301,6 @@ jobs:
293301 steps :
294302 - uses : actions/checkout@v3
295303
296- - name : Create pip cache dir
297- run : mkdir -p ~/.cache/pip
298-
299- - name : Cache wheels
300- uses : actions/cache@v3
301- with :
302- path : ~/.cache/pip
303- key : ${{ runner.os }}-doc-pip-${{ hashFiles('setup.cfg', 'pyproject.toml', 'requirements_tests.txt') }}
304- restore-keys : ${{ runner.os }}-doc-pip-
305-
306304 - name : Get history and tags for SCM versioning to work
307305 if : ${{ !env.ACT }}
308306 run : |
@@ -313,6 +311,10 @@ jobs:
313311 with :
314312 python-version : ' 3.x'
315313 architecture : ' x64'
314+ cache : ' pip'
315+ cache-dependency-path : |
316+ setup.cfg
317+ pyproject.toml
316318
317319 - name : Install docs & setup requirements
318320 run : |
0 commit comments