system_baseline capped the persistent journal on every host with no way to opt out, and wrote system_baseline_journal_max_use into the drop-in unchecked: an empty value produced an empty SystemMaxUse=, and a bare number, a typo or a line break went into the file as it was.
tasks/main.yml: the journald import has when: system_baseline_journal_max_use | length > 0, as the apt-daily import does. With an empty value there is no drop-in directory, no drop-in file and no restart of systemd-journald. A file an earlier run wrote stays (the issue's proposal, matching the apt-daily input).
tasks/validate.yml (tag always, so --tags journald validates too): the value is empty, infinity, or a number followed by K, M, G or T. A bare number, a space or a line break stops the run before any change, with a message that names the input.
argument_specs, README (table row, a section "Leaving journald alone", the Tests list), a comment in defaults/main.yml, and a minor_changes fragment. The default stays 200M.
Tests: converge refuses "300", "0", 10 M, 10m, a value with a line break and the integer 300 (new tasks/refuse_journal_max_use.yml); the last play of verify.yml removes the drop-in, runs the role with an empty value and asserts that no drop-in directory exists and that journald's ActiveEnterTimestampMonotonic did not change.
Decisions you may want to look at
The pattern is stricter than systemd's. Before, any string reached the file. Now 1.5G and the P/E suffixes stop the run, because the issue names K, M, G and T. If you want them, it is one regex in tasks/validate.yml. The fragment says that a form which used to be written as it was now stops the run.
0M passes while 0 is refused. It is the same zero-byte cap in a valid form; refusing it would need a rule on the number.
On a Debian host with ansible-core 2.22.0, in check mode with --tags journald,always against this branch: 200M, infinity, 2G and 0M validate and reach the drop-in tasks; an empty value skips both journald tasks; "300", "0", "10 M", "10m", "200M\nStorage=none", the integer 300 and infinite each stop with the message that names the input.
An independent read-only review found no blocking defect; its findings (a comment left above the wrong task, a message that claimed an integer is not a string, a stale-state note for a second local molecule verify, the stricter pattern) are fixed or listed above.
Not verified
Molecule: it runs only in CI. In particular nothing here proves that systemctl show systemd-journald --property=ActiveEnterTimestampMonotonic behaves as the new assertion expects in the container, or that the last verify.yml play (a full role run with defaults) leaves nothing that matters. It runs last, because it removes the drop-in and the tmux snippet the converge wrote; a second molecule verify without a converge fails by design.
That journald accepts infinity for SystemMaxUse, and its exact size syntax (decimals, P, E): I could not check the manual offline.
I confirm third-party material is recorded in NOTICE and REUSE.toml, or there is none. (None.)
Assisted-by: Claude Code:claude-sonnet-5-5
## What and why
Closes #401
`system_baseline` capped the persistent journal on every host with no way to opt out, and wrote `system_baseline_journal_max_use` into the drop-in unchecked: an empty value produced an empty `SystemMaxUse=`, and a bare number, a typo or a line break went into the file as it was.
- `tasks/main.yml`: the journald import has `when: system_baseline_journal_max_use | length > 0`, as the apt-daily import does. With an empty value there is no drop-in directory, no drop-in file and no restart of `systemd-journald`. A file an earlier run wrote stays (the issue's proposal, matching the apt-daily input).
- `tasks/validate.yml` (tag `always`, so `--tags journald` validates too): the value is empty, `infinity`, or a number followed by `K`, `M`, `G` or `T`. A bare number, a space or a line break stops the run before any change, with a message that names the input.
- argument_specs, README (table row, a section "Leaving journald alone", the Tests list), a comment in `defaults/main.yml`, and a `minor_changes` fragment. The default stays `200M`.
- Tests: converge refuses `"300"`, `"0"`, `10 M`, `10m`, a value with a line break and the integer `300` (new `tasks/refuse_journal_max_use.yml`); the last play of `verify.yml` removes the drop-in, runs the role with an empty value and asserts that no drop-in directory exists and that journald's `ActiveEnterTimestampMonotonic` did not change.
## Decisions you may want to look at
- **The pattern is stricter than systemd's.** Before, any string reached the file. Now `1.5G` and the `P`/`E` suffixes stop the run, because the issue names K, M, G and T. If you want them, it is one regex in `tasks/validate.yml`. The fragment says that a form which used to be written as it was now stops the run.
- **`0M` passes** while `0` is refused. It is the same zero-byte cap in a valid form; refusing it would need a rule on the number.
- **`infinity`** is accepted because the issue lists it.
## Verified
- All commit-stage hooks passed (ansible-lint, yamllint, changelog fragments lint, REUSE, Conventional Commit, `Assisted-by`).
- On a Debian host with ansible-core 2.22.0, in check mode with `--tags journald,always` against this branch: `200M`, `infinity`, `2G` and `0M` validate and reach the drop-in tasks; an empty value skips both journald tasks; `"300"`, `"0"`, `"10 M"`, `"10m"`, `"200M\nStorage=none"`, the integer `300` and `infinite` each stop with the message that names the input.
- An independent read-only review found no blocking defect; its findings (a comment left above the wrong task, a message that claimed an integer is not a string, a stale-state note for a second local `molecule verify`, the stricter pattern) are fixed or listed above.
## Not verified
- Molecule: it runs only in CI. In particular nothing here proves that `systemctl show systemd-journald --property=ActiveEnterTimestampMonotonic` behaves as the new assertion expects in the container, or that the last `verify.yml` play (a full role run with defaults) leaves nothing that matters. It runs last, because it removes the drop-in and the tmux snippet the converge wrote; a second `molecule verify` without a converge fails by design.
- That journald accepts `infinity` for `SystemMaxUse`, and its exact size syntax (decimals, `P`, `E`): I could not check the manual offline.
---
- [x] I confirm third-party material is recorded in `NOTICE` and `REUSE.toml`, or there is none. (None.)
Assisted-by: Claude Code:claude-sonnet-5-5
The role capped the persistent journal on every host with no way to opt
out, and wrote the value into the drop-in unchecked: an empty value
produced an empty SystemMaxUse=, and a bare number, a typo or a line
break went into the file as it was.
An empty system_baseline_journal_max_use now skips the journald task, as
an empty system_baseline_apt_daily_timeout skips its task: no drop-in
directory, no drop-in file and no restart of systemd-journald. A file an
earlier run wrote stays.
Any other value is checked before any change: infinity, or a number
followed by K, M, G or T. A bare number, a space and a line break stop
the run with a message that names the input. The default stays 200M.
Closes#401
Assisted-by: Claude Code:claude-sonnet-5-5
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.
What and why
Closes #401
system_baselinecapped the persistent journal on every host with no way to opt out, and wrotesystem_baseline_journal_max_useinto the drop-in unchecked: an empty value produced an emptySystemMaxUse=, and a bare number, a typo or a line break went into the file as it was.tasks/main.yml: the journald import haswhen: system_baseline_journal_max_use | length > 0, as the apt-daily import does. With an empty value there is no drop-in directory, no drop-in file and no restart ofsystemd-journald. A file an earlier run wrote stays (the issue's proposal, matching the apt-daily input).tasks/validate.yml(tagalways, so--tags journaldvalidates too): the value is empty,infinity, or a number followed byK,M,GorT. A bare number, a space or a line break stops the run before any change, with a message that names the input.defaults/main.yml, and aminor_changesfragment. The default stays200M."300","0",10 M,10m, a value with a line break and the integer300(newtasks/refuse_journal_max_use.yml); the last play ofverify.ymlremoves the drop-in, runs the role with an empty value and asserts that no drop-in directory exists and that journald'sActiveEnterTimestampMonotonicdid not change.Decisions you may want to look at
1.5Gand theP/Esuffixes stop the run, because the issue names K, M, G and T. If you want them, it is one regex intasks/validate.yml. The fragment says that a form which used to be written as it was now stops the run.0Mpasses while0is refused. It is the same zero-byte cap in a valid form; refusing it would need a rule on the number.infinityis accepted because the issue lists it.Verified
Assisted-by).--tags journald,alwaysagainst this branch:200M,infinity,2Gand0Mvalidate and reach the drop-in tasks; an empty value skips both journald tasks;"300","0","10 M","10m","200M\nStorage=none", the integer300andinfiniteeach stop with the message that names the input.molecule verify, the stricter pattern) are fixed or listed above.Not verified
systemctl show systemd-journald --property=ActiveEnterTimestampMonotonicbehaves as the new assertion expects in the container, or that the lastverify.ymlplay (a full role run with defaults) leaves nothing that matters. It runs last, because it removes the drop-in and the tmux snippet the converge wrote; a secondmolecule verifywithout a converge fails by design.infinityforSystemMaxUse, and its exact size syntax (decimals,P,E): I could not check the manual offline.NOTICEandREUSE.toml, or there is none. (None.)Assisted-by: Claude Code:claude-sonnet-5-5