Skip to content

POSIX e2e: start mosquitto without a config file; run on ubuntu-latest again - #35

Merged
dcj merged 1 commit into
mainfrom
ci/ubuntu-26.04-mosquitto
Nov 14, 2026
Merged

dcj merged 1 commit into
mainfrom
ci/ubuntu-26.04-mosquitto

Conversation

@dcj

@dcj dcj commented Nov 14, 2026

Copy link
Copy Markdown
Contributor

Ubuntu 26.04's apparmor package ships /etc/apparmor.d/mosquitto, which confines /usr/sbin/mosquitto to config files under /etc/mosquitto. The harness wrote its mosquitto.conf in the test's work directory, so mosquitto logged Error: Unable to open config file and every end-to-end test failed at port_open. The 24.04 package has no profile, which is why #33's pin worked. A plain ubuntu:26.04 container does not enforce the profile, so it does not reproduce there.

The harness now starts mosquitto -p <port> with no config file. In that mode mosquitto 2.x:

  • listens on loopback only,
  • allows anonymous clients,
  • keeps no persistence,

which is what the config file set. It also prints mosquitto.log when the broker does not listen, since a CI runner's work directory is gone afterwards. This puts the POSIX job back on ubuntu-latest, undoing #33.

Checked:

  • all 8 end-to-end tests pass locally (macOS, mosquitto 2.1.2);
  • config-free mosquitto 2.0.22 accepts an anonymous publish in an ubuntu:26.04 container;
  • this PR's CI runs the job on 26.04.

🤖 Generated with Claude Code

https://claude.ai/code/session_01VUQ6asqTe3tYwnZR7GW2dn

…t again

Ubuntu 26.04's apparmor package confines /usr/sbin/mosquitto to config files
under /etc/mosquitto, so the file the harness wrote in its work directory
could not be read ("Unable to open config file") and every end-to-end test
failed at port_open. Without a config file mosquitto 2.x listens on loopback
only, allows anonymous clients and keeps no persistence, which is what the
tests set. The harness now also prints mosquitto.log when the broker does not
listen. This undoes the ubuntu-24.04 pin from #33.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01VUQ6asqTe3tYwnZR7GW2dn
@dcj
dcj merged commit e25a8fc into main Nov 14, 2026
8 checks passed
@dcj
dcj deleted the ci/ubuntu-26.04-mosquitto branch November 14, 2026 17:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant