fix(ci): allow extension namespaces in quality container
Quality / check (push) Canceled after 3m57s
Quality / check (push) Canceled after 3m57s
This commit is contained in:
1 file changed
+10
-4
@@ -15,6 +15,10 @@ concurrency:
|
||||
jobs:
|
||||
check:
|
||||
runs-on: ubuntu-latest
|
||||
container:
|
||||
image: docker.gitea.com/runner-images:ubuntu-latest
|
||||
# Docker's default seccomp policy blocks the extension's user/network namespaces.
|
||||
options: --security-opt seccomp=unconfined
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
with:
|
||||
@@ -62,10 +66,12 @@ jobs:
|
||||
git branch main origin/main
|
||||
fi
|
||||
|
||||
# Extensions run in an unprivileged user and network namespace, which
|
||||
# Ubuntu 24.04 runners forbid through AppArmor by default.
|
||||
- name: Allow unprivileged user namespaces
|
||||
run: sudo sysctl -w kernel.apparmor_restrict_unprivileged_userns=0
|
||||
- name: Verify extension namespace support
|
||||
run: |
|
||||
if [ -e /proc/sys/kernel/apparmor_restrict_unprivileged_userns ]; then
|
||||
sudo sysctl -w kernel.apparmor_restrict_unprivileged_userns=0
|
||||
fi
|
||||
unshare --user --map-root-user --net true
|
||||
|
||||
- name: Run definitive gate
|
||||
run: |
|
||||
|
||||
Reference in new issue
Block a user