chore(deploy): install p7zip + coreutils for script-overlay tooling
Script overlays commonly need 7z and md5sum (e.g. the l4d2center map sync recipe). Add p7zip-full to the apt install line, p7zip + p7zip-plugins to dnf, and coreutils explicitly so md5sum is guaranteed even on slim base images. Lock both in with a regression test. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This commit is contained in:
parent
406f2196f8
commit
ebddb0fab2
2 changed files with 20 additions and 2 deletions
|
|
@ -85,9 +85,9 @@ fi
|
|||
|
||||
if command -v apt-get >/dev/null 2>&1; then
|
||||
$sudo_cmd apt-get update
|
||||
$sudo_cmd apt-get install -y python3 python3-venv python3-pip curl ca-certificates tar gzip util-linux sudo
|
||||
$sudo_cmd apt-get install -y python3 python3-venv python3-pip curl ca-certificates tar gzip util-linux sudo coreutils p7zip-full
|
||||
elif command -v dnf >/dev/null 2>&1; then
|
||||
$sudo_cmd dnf install -y python3 python3-pip curl ca-certificates tar gzip util-linux sudo
|
||||
$sudo_cmd dnf install -y python3 python3-pip curl ca-certificates tar gzip util-linux sudo coreutils p7zip p7zip-plugins
|
||||
else
|
||||
printf 'Unsupported package manager: expected apt-get or dnf\n' >&2
|
||||
exit 1
|
||||
|
|
|
|||
|
|
@ -306,6 +306,24 @@ def test_deploy_script_does_not_install_bubblewrap():
|
|||
assert "bwrap" not in line, line
|
||||
|
||||
|
||||
def test_deploy_script_installs_script_overlay_tooling():
|
||||
# Script overlays commonly need 7z and md5sum (e.g. l4d2center map sync).
|
||||
# coreutils ships md5sum and is technically essential, but listing it
|
||||
# explicitly makes the contract obvious and survives slim base images.
|
||||
script = DEPLOY_SCRIPT.read_text().splitlines()
|
||||
apt_lines = [l for l in script if "apt-get install" in l]
|
||||
dnf_lines = [l for l in script if "dnf install" in l]
|
||||
assert apt_lines, "expected an apt-get install line"
|
||||
assert dnf_lines, "expected a dnf install line"
|
||||
for line in apt_lines:
|
||||
assert "p7zip-full" in line, line
|
||||
assert "coreutils" in line, line
|
||||
for line in dnf_lines:
|
||||
# Fedora/RHEL split: p7zip provides 7za, p7zip-plugins provides 7z.
|
||||
assert "p7zip" in line and "p7zip-plugins" in line, line
|
||||
assert "coreutils" in line, line
|
||||
|
||||
|
||||
def test_deploy_script_tightens_left4me_db_permissions():
|
||||
script = DEPLOY_SCRIPT.read_text()
|
||||
# The DB and its WAL/SHM sidecars must be left4me:left4me 0640 — owner
|
||||
|
|
|
|||
Loading…
Reference in a new issue