provision: fail fast when the role script is missing
A missing seed payload used to look like a hung stage: the scheduled task exited immediately and backend_wait polled for an hour. Both backends now check Test-Path on the role script before scheduling it.
This commit is contained in:
@@ -297,6 +297,12 @@ backend_ready() {
|
||||
|
||||
backend_start() {
|
||||
local name=$1 remote=$2
|
||||
|
||||
if ! _labwinrm "$name" ps "Test-Path '${remote}'" 2>/dev/null | grep -qi true; then
|
||||
fail "$name: ${remote} is missing — the seed payload was not copied"
|
||||
return 1
|
||||
fi
|
||||
|
||||
_labwinrm "$name" start "$remote"
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user