diff --git a/.github/workflows/reproducible-builds.yml b/.github/workflows/reproducible-builds.yml index 8ff6de3c43..ffc3fa15f0 100644 --- a/.github/workflows/reproducible-builds.yml +++ b/.github/workflows/reproducible-builds.yml @@ -107,12 +107,13 @@ jobs: if: matrix.runner == 'ubuntu-24.04' shell: bash run: | - sysctl --ignore --write kernel.apparmor_restrict_unprivileged_unconfined=0 - sysctl --ignore --write kernel.apparmor_restrict_unprivileged_userns=0 + # Taken from https://github.com/systemd/mkosi/blob/fcacc94b9f72d9b6b1f03779b0c6e07209ceb54b/action.yaml#L42-L57. + sudo sysctl --ignore --write kernel.apparmor_restrict_unprivileged_unconfined=0 + sudo sysctl --ignore --write kernel.apparmor_restrict_unprivileged_userns=0 # This command fails with a non-zero error code even though it unloads the apparmor profiles. # https://gitlab.com/apparmor/apparmor/-/issues/403 - aa-teardown || true - apt-get remove -y apparmor + sudo aa-teardown || true + sudo apt-get remove -y apparmor - name: Checkout uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4.1.7