Skip to content

test: load aa-profiles with compatible ABIs for the host #236

test: load aa-profiles with compatible ABIs for the host

test: load aa-profiles with compatible ABIs for the host #236

Workflow file for this run

name: codejail-ci
on:
push:
branches:
- master
pull_request:
jobs:
codejail_ci:
name: tests
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
include:
- python_version: '3.11'
ubuntu_version: '20.04'
os: "ubuntu-20.04"
- python_version: '3.11'
ubuntu_version: '22.04'
os: "ubuntu-22.04"
- python_version: '3.11'
ubuntu_version: '24.04'
os: "ubuntu-24.04"
steps:
- uses: actions/checkout@v4
- name: Parse custom apparmor profile with default feature ABI
if: ${{ matrix.ubuntu_version == '20.04' }}
run: sudo apparmor_parser -r -W apparmor-profiles/home.sandbox.codejail_sandbox-python3.bin.python-default-abi
- name: Parse custom apparmor profile with ABI 3.0
if: ${{ matrix.ubuntu_version != '20.04' }}
run: sudo apparmor_parser -r -W apparmor-profiles/home.sandbox.codejail_sandbox-python3.bin.python-abi3
- name: Build latest code changes into CI image
run: |
docker build -t openedx-codejail \
--cache-to type=gha \
--cache-from type=gha \
--build-arg python_version=${{ matrix.python_version }} \
--build-arg ubuntu_version=${{ matrix.ubuntu_version }} .
- name: Run container with custom apparmor profile and codejail CI image
run: |
docker run --name=codejail --privileged -d --security-opt apparmor=apparmor_profile \
openedx-codejail tail -f /dev/null
- name: Run Non Proxy Tests
run: docker exec -t codejail bash -c 'make clean && make test_no_proxy'
- name: Run Proxy Tests
run: docker exec -t codejail bash -c 'make clean && make test_proxy'
- name: Run Quality Tests
run: docker exec -t codejail bash -c 'make quality'