fix(oci): prepare managed format directories before startup

This commit is contained in:
VAIO73
2026-10-19 12:23:49 +00:00
parent 29778aa709
commit 3e9c9eb25d
10 changed files with 694 additions and 34 deletions
+7
View File
@@ -5,6 +5,13 @@
case "$1" in
''|*[!0-9]*) exit 0 ;;
esac
# Direct PVE restore formats managed filesystems again. The installed record
# authorizes this narrow cleanup; missing/busy records leave the guest alone.
# A hook failure must not prevent the console marker or the DHCP timer.
volumes="${0%/*}/oci_managed_volumes.py"
if [ -r "$volumes" ] && command -v timeout >/dev/null 2>&1; then
timeout --signal=TERM --kill-after=2 10 python3 "$volumes" startup "$1" >/dev/null 2>&1 || :
fi
printf '\n=== ProxMenux: container started %s ===\n' "$(date '+%Y-%m-%d %H:%M:%S')" \
>> "/var/log/proxmenux/oci/$1.console.log" 2>/dev/null
lease="${0%/*}/oci_dhcp_lease.py"