Skip to content

Commit 1bf614b

Browse files
Update test installation for Python 3.12
The test installation now includes Python 3.12. Signed-off-by: Daniel Zullo <[email protected]>
1 parent 70902b5 commit 1bf614b

File tree

3 files changed

+27
-2
lines changed

3 files changed

+27
-2
lines changed
File renamed without changes.
Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
# License: MIT
2+
# Copyright © 2024 Frequenz Energy-as-a-Service GmbH
3+
# This Dockerfile is used to test the installation of the python package in
4+
# multiple platforms in the CI. It is not used to build the package itself.
5+
6+
FROM --platform=${TARGETPLATFORM} python:3.12-slim
7+
8+
RUN apt-get update -y && \
9+
apt-get install --no-install-recommends -y \
10+
git && \
11+
apt-get clean && \
12+
rm -rf /var/lib/apt/lists/* && \
13+
python -m pip install --upgrade --no-cache-dir pip
14+
15+
COPY dist dist
16+
RUN pip install dist/*.whl && \
17+
rm -rf dist

.github/workflows/ci.yaml

Lines changed: 10 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -241,7 +241,15 @@ jobs:
241241
test-installation:
242242
name: Test package installation in different architectures
243243
needs: ["build"]
244-
runs-on: ubuntu-20.04
244+
strategy:
245+
fail-fast: false
246+
matrix:
247+
os:
248+
- ubuntu-20.04
249+
python:
250+
- "3.11"
251+
- "3.12"
252+
runs-on: ${{ matrix.os }}
245253
steps:
246254
- name: Fetch sources
247255
uses: actions/checkout@v4
@@ -258,7 +266,7 @@ jobs:
258266
uses: docker/build-push-action@v5
259267
with:
260268
context: .
261-
file: .github/containers/test-installation/Dockerfile
269+
file: .github/containers/test-installation/python-${{ matrix.python }}.Dockerfile
262270
platforms: linux/amd64,linux/arm64
263271
tags: localhost/test-installation
264272
push: false

0 commit comments

Comments
 (0)