Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Let systemd create directories #3122

Open
wants to merge 1 commit into
base: develop
Choose a base branch
from

Commits on Oct 4, 2024

  1. Let systemd create directories

    Manually creating directories conflicts with systemd service hardening
    features. Particularly, `ProtectSystem=strict` mounts the filesystem as
    read-only for the processes started by the unit which leads to `mkdir`
    failing.
    
    By setting `User=mosquitto` and adding `RuntimeDirectory` and
    `LogsDirectory`, systemd creates `/run/mosquitto` and
    `/var/log/mosquitto` with the right permissions even
    `ProtectSystem=strict` is used.
    
    Signed-off-by: Guillaume Champagne <[email protected]>
    gchamp20 committed Oct 4, 2024
    Configuration menu
    Copy the full SHA
    cb4d276 View commit details
    Browse the repository at this point in the history