Skip to content

Stop GPG agent before removing signature-verification home - #1273

Merged
brunoborges merged 2 commits into
mainfrom
copilot/verify-signature-cleanup-fix
Sep 29, 2026
Merged

brunoborges merged 2 commits into
mainfrom
copilot/verify-signature-cleanup-fix

Conversation

Copilot AI commented Sep 28, 2026 •

Copy link
Copy Markdown
Contributor

Description:
On self-hosted runners with NFS-backed RUNNER_TEMP, signature verification can succeed but the step can fail while removing an agent-held .nfs* file.

  • Cleanup: Stop the verification GPG agent before removing its temporary home, reusing the existing best-effort shutdown behavior.
  • Coverage: Add tests for cleanup after successful and failed verification, including when gpgconf is unavailable.

Related issue:
NFS-backed RUNNER_TEMP signature-verification cleanup failure.

Download URL:
Not applicable; no new distribution.

License:
Not applicable; no new distribution.

Check list:

  • Mark if documentation changes are required.
  • Mark if tests were added or updated to cover the changes.
  • Mark if new distribution is being added.

Co-authored-by: brunoborges <129743+brunoborges@users.noreply.github.com>
Copilot AI changed the title [WIP] Fix cleanup failure due to EBUSY error in GPG signature verification Stop GPG agent before removing signature-verification home Sep 28, 2026
Copilot AI requested a review from brunoborges September 28, 2026 22:45
@brunoborges
brunoborges marked this pull request as ready for review September 28, 2026 23:47
@brunoborges
brunoborges requested a review from a team as a code owner September 28, 2026 23:47
Copilot AI balanced review requested due to automatic review settings September 28, 2026 23:47

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot review overview

🟢 Approval recommended

The implementation, generated bundles, and tests consistently address the reported NFS cleanup failure.

Review effort: Balanced
Findings: None

What changed in this PR

Stops temporary GPG agents before deleting signature-verification homes, preventing NFS cleanup failures.

Changes:

  • Extracts reusable best-effort GPG agent shutdown.
  • Applies shutdown to verification cleanup.
  • Adds success, failure, and unavailable-gpgconf coverage.
File Description
src/​gpg.ts Stops agents before home removal.
__tests__/​gpg.test.ts Covers all cleanup outcomes.
dist/​setup/​81.index.js Updates generated setup bundle.
dist/​setup/​220.index.js Updates generated setup bundle.
dist/​setup/​463.index.js Updates generated setup bundle.
dist/​cleanup/​index.js Updates generated cleanup bundle.

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

@brunoborges
brunoborges merged commit a78ec39 into main Sep 29, 2026
86 checks passed
@brunoborges
brunoborges deleted the copilot/verify-signature-cleanup-fix branch September 29, 2026 01:26
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

verify-signature cleanup fails with EBUSY when RUNNER_TEMP is on NFS (self-hosted, v6.0.0)

3 participants