Skip to content

Commit 717c176

Browse files
committed
tests/multi-server: also unconfine apparmor on the kafka broker
The previous seccomp:unconfined change flipped redpanda's first-stage failure mode (perf_event_open now EACCES from the kernel sysctl, instead of EPERM from seccomp) but the fatal close() EINVAL during seastar reactor init still fired. On DinD runners the inner containers inherit the default docker-default AppArmor profile in addition to seccomp, and that profile is what's driving the EINVAL. Opt out of both sandboxes for the test broker.
1 parent 3e94db1 commit 717c176

1 file changed

Lines changed: 9 additions & 6 deletions

File tree

src/tests/multi-server/environments/kafka.yml.j2

Lines changed: 9 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -32,14 +32,17 @@ services:
3232
kafka:
3333
image: docker.redpanda.com/redpandadata/redpanda:latest
3434
# Redpanda's seastar reactor opens io_uring / eventfd / perf_event
35-
# fds during startup; the default Docker seccomp profile on the
36-
# self-hosted CI runners blocks enough of those that close() fails
37-
# with EINVAL on a stale handle and the broker aborts during init.
38-
# (Local Docker Desktop's profile is looser and doesn't hit this.)
39-
# Relaxing seccomp for this single service unblocks CI without
40-
# giving the broker any broader host access.
35+
# fds during startup; the default Docker seccomp AND AppArmor
36+
# profiles on the self-hosted CI runners between them block enough
37+
# of those that close() fails with EINVAL on a stale handle and the
38+
# broker aborts during init. (Local Docker Desktop's profiles are
39+
# looser and don't hit this.) Opting the kafka service out of both
40+
# sandboxes unblocks CI without giving the broker any broader host
41+
# access - it only talks to the two other containers on the compose
42+
# network.
4143
security_opt:
4244
- seccomp:unconfined
45+
- apparmor:unconfined
4346
# Override the default command to advertise the broker under its
4447
# compose service name. Without this the broker tells clients to
4548
# reconnect at 127.0.0.1:9092 which only works when client and

0 commit comments

Comments
 (0)