fix: stabilize live linux and windows e2e agent flows#5
Merged
Conversation
Use a short Windows launcher script for scheduled tasks so the real hosted E2E run stays under schtasks /TR limits, and delete the launcher during agent self-removal. Fix the Linux live wrapper generation by preventing heredoc expansion while writing the isolated tailscale wrapper, then assert the Windows launcher exists and is removed in the live test.
Generate short-lived Linux and Windows auth keys from the Tailscale API during the live workflow so reruns do not depend on stale or one-shot stored auth keys. Also move the Linux live workdir to /var/tmp and recreate it after package installation, then update the docs to match the new secret requirements.
Fix the Linux wrapper script so its internal variables expand at runtime, and switch the Windows live test to verify scheduled tasks through schtasks instead of Get-ScheduledTask.
Avoid starting the Linux oneshot agent service during enrollment so the timer does not race the initial lease state, and treat a 404 device delete as already cleaned for ephemeral Windows nodes.
Add per-request timeouts and explicit progress markers to the Windows live E2E script so stalled Tailscale API calls do not hang the workflow without actionable output.
Wrap the Windows live E2E CLI invocations with explicit subprocess timeouts and captured output so hangs report the exact failing phase instead of consuming the entire job timeout.
Use a detached PowerShell Start-Process launcher for delayed Windows self-deletion so agent --once can return after cleanup instead of blocking on the cmd start chain.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
agent --oncepathVerification
go test ./...bash -n tests/live/linux-live-e2e.shtests/live/windows-live-e2e.ps1242146888567069222237570692222401Root Cause
agent run ..., but the CLI only supportsagent ...