Skip to content

Commit

Permalink
Fix container build with python 3.11
Browse files Browse the repository at this point in the history
- Switch to 3.11 in pyproject.toml and acceptance.yml
  • Loading branch information
pehala committed Oct 19, 2023
1 parent d48c084 commit f9f4711
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 6 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/acceptance.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,10 +14,10 @@ jobs:
id: setup-python
uses: actions/setup-python@v4
with:
python-version: '3.9'
python-version: '3.11'
cache: "poetry"
cache-dependency-path: "pyproject.toml"
- name: Install dependencies
run: poetry install --no-root
run: poetry install
- name: Run acceptance check
run: make -k commit-acceptance
6 changes: 3 additions & 3 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ Bind kubeconfig to /opt/kubeconfig \
Bind a dir to /test-run-results to get reports "

RUN useradd --no-log-init -u 1001 -g root -m testsuite
RUN dnf install -y python3.11 pip make git && dnf clean all
RUN dnf install -y python3.11 python3.11-pip make git && dnf clean all

RUN curl https://mirror.openshift.com/pub/openshift-v4/clients/ocp/stable/openshift-client-linux.tar.gz >/tmp/oc.tgz && \
tar xzf /tmp/oc.tgz -C /usr/local/bin && \
Expand All @@ -15,7 +15,7 @@ RUN curl https://mirror.openshift.com/pub/openshift-v4/clients/ocp/stable/opensh
RUN curl -L https://github.com/cloudflare/cfssl/releases/download/v1.6.3/cfssl_1.6.3_linux_amd64 >/usr/bin/cfssl && \
chmod +x /usr/bin/cfssl

RUN python3 -m pip --no-cache-dir install poetry
RUN python3.11 -m pip --no-cache-dir install poetry

WORKDIR /opt/workdir/marin3r-testsuite

Expand All @@ -33,7 +33,7 @@ ENV KUBECONFIG=/run/kubeconfig \
junit=yes \
resultsdir=/test-run-results

RUN poetry install --no-root
RUN poetry env use python3.11 && poetry install

ENTRYPOINT [ "make" ]
CMD [ "test" ]
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ readme = "README.md"
packages = [{include = "marin3r_testsuite"}]

[tool.poetry.group.main.dependencies]
python = "^3.9"
python = "^3.11"
typing_extensions = "*"
pytest-xdist = "*"
pytest = "*"
Expand Down

0 comments on commit f9f4711

Please sign in to comment.