install from a hand-written oci-compose; Log2RAM journal fix

OCI manager Apps
- "Install an image that is not in the catalog" reads an oci-compose from a file of the host or from an address.
- A file written by hand states the image, its ports, variables and volumes, and what the installation asks; the rest is completed when it is read. A complete file, or the record of an installation, is installed as it is, and of a record only the template is used.
- Errors name the field they are in, also on a host without python3-jsonschema.
- oci/README.md describes the engine and the oci-compose block by block, with two examples in oci/examples/.
- The documentation page of the option covers it, in English and Spanish.

Log2RAM (reported by @f3rs3n)
- The sync removes the old active journal file from the disk copy, so a boot no longer restores it and journald deletes its oldest archives first. Log2RAM optimization 1.7; it takes effect from the next reboot.

Translations
- The bot keeps "oci-compose" as written.
- Spanish texts for the new option and for the Log2RAM notice.
This commit is contained in:
MacRimi
2026-10-12 22:29:08 +02:00
parent 9089f79342
commit cc12c625a6
15 changed files with 1560 additions and 45 deletions
+15
View File
@@ -401,3 +401,18 @@ pmx_rebuild_dkms_after_kernel() {
fi
return 0
}
# Log2RAM syncs only the archived journal files, so the active file it found
# on disk when it was installed stays there. Restored at every boot, it makes
# journald continue an old sequence and delete its newest archives first.
# The sync removes that file from the disk copy. Returns 0 when it changes
# the given Log2RAM script.
pmx_log2ram_drop_stale_journal() {
local log2ram_bin="$1"
[[ -f "$log2ram_bin" ]] || return 1
grep -q -- '--exclude=journal/\*/\*' "$log2ram_bin" 2>/dev/null || return 1
grep -q -- '--delete-excluded' "$log2ram_bin" 2>/dev/null && return 1
[[ -e "${log2ram_bin}.proxmenux.bak" ]] || cp -a "$log2ram_bin" "${log2ram_bin}.proxmenux.bak"
sed '/optional_params+=("--exclude=journal\/\*\/\*")/a\ optional_params+=("--delete-excluded")' "$log2ram_bin" \
| pmx_write_file "$log2ram_bin"
}