Skip to content

Commit

Permalink
Merge pull request #873 from p12tic/github-run-container
Browse files Browse the repository at this point in the history
github: Run actions on python:3.11-bookworm
  • Loading branch information
p12tic authored Mar 8, 2024
2 parents 5b57194 + 7c81044 commit 16a90e2
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 10 deletions.
9 changes: 5 additions & 4 deletions .github/workflows/static-checks.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,12 +7,13 @@ on:
jobs:
static-checks:
runs-on: ubuntu-latest
container:
image: docker.io/library/python:3.11-bookworm
# cgroupns needed to address the following error:
# write /sys/fs/cgroup/cgroup.subtree_control: operation not supported
options: --privileged --cgroupns=host
steps:
- uses: actions/checkout@v3
- name: Set up Python 3.10
uses: actions/setup-python@v5
with:
python-version: "3.11"
- name: Analysing the code with ruff
run: |
pip install -r test-requirements.txt
Expand Down
13 changes: 7 additions & 6 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,16 +7,17 @@ on:
jobs:
test:
runs-on: ubuntu-latest

container:
image: docker.io/library/python:3.11-bookworm
# cgroupns needed to address the following error:
# write /sys/fs/cgroup/cgroup.subtree_control: operation not supported
options: --privileged --cgroupns=host
steps:
- uses: actions/checkout@v3
- name: Set up Python 3.10
uses: actions/setup-python@v5
with:
python-version: "3.10"
- name: Install dependencies
run: |
sudo apt update && sudo apt install -y podman
set -e
apt update && apt install -y podman
python -m pip install --upgrade pip
if [ -f requirements.txt ]; then pip install -r requirements.txt; fi
if [ -f test-requirements.txt ]; then pip install -r test-requirements.txt; fi
Expand Down

0 comments on commit 16a90e2

Please sign in to comment.