ci: allow unrestricted user namespaces in image builds (#3587)

Since Ubuntu 23.10, creating namespaces, e.g. via `unshare`, requires
privileges. Since `unshare` is used by `mkosi` in our image build
pipeline, we need to re-enable them explicitly here before building the
image, aligning with the behavior before Ubuntu 23.10.
This commit is contained in:
Moritz Sanft 2025-01-17 09:36:48 +01:00 committed by GitHub
parent 0272e7dd15
commit 6ba47d5634
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -167,6 +167,12 @@ jobs:
with:
clouds_yaml: ${{ secrets.STACKIT_IMAGE_UPLOAD_CLOUDS_YAML }}
- name: Allow unrestricted user namespaces
shell: bash
run: |
sudo sysctl --ignore --write kernel.apparmor_restrict_unprivileged_unconfined=0
sudo sysctl --ignore --write kernel.apparmor_restrict_unprivileged_userns=0
- name: Build and upload
id: build
shell: bash