mirror of
https://github.com/warmbly/warmbly.git
synced 2026-10-21 16:03:12 +00:00
feat: validate Linux enrollment fixture prerequisites before persisting retry-safe node identity in the join checker
Co-Authored-By: Devin AI <158243242+devin-ai-integration[bot]@users.noreply.github.com>
This commit is contained in:
co-authored by
Devin AI
parent
a9d1865a69
commit
e9a819e552
@@ -224,6 +224,12 @@ printf '%s\n' "$local_body" | awk '
|
||||
|| fail "ensure_local_env must test for an existing file before writing one, or a re-join truncates the operator's file"
|
||||
ok "an existing local override file is never truncated"
|
||||
|
||||
if ! command -v flock >/dev/null 2>&1; then
|
||||
fail "enrollment fixture requires util-linux flock"
|
||||
fi
|
||||
[ -r /proc/sys/kernel/random/uuid ] \
|
||||
|| fail "enrollment fixture requires /proc/sys/kernel/random/uuid"
|
||||
|
||||
join_fixture=$(mktemp -d)
|
||||
trap 'rm -rf "$join_fixture"' EXIT HUP INT TERM
|
||||
sed '$d' "$SCRIPT" > "$join_fixture/functions.sh"
|
||||
|
||||
Reference in New Issue
Block a user