fix: macOS compatibility for copilot CLI install + FAQ on macOS runners#16970
fix: macOS compatibility for copilot CLI install + FAQ on macOS runners#16970
Conversation
There was a problem hiding this comment.
Pull request overview
This PR fixes cross-platform compatibility issues in the Copilot CLI installation script by replacing hardcoded Linux-specific paths with environment variables. The issue was preventing the "Smoke macOS ARM64" workflow from succeeding, as macOS runners use /Users/runner instead of /home/runner for the home directory.
Changes:
- Replace hardcoded
/home/runner/.copilotwith${HOME}/.copilotfor cross-platform home directory support - Replace hardcoded
runner:runnerownership with$(whoami)for dynamic user detection
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
|
🧪 Smoke Project is now testing project operations... |
|
🧪 Smoke Temporary ID is now testing temporary ID functionality... |
|
✨ The prophecy is fulfilled... Smoke Codex has completed its mystical journey. The stars align. 🌟 |
|
📰 BREAKING: Smoke Copilot is now investigating this pull request. Sources say the story is developing... |
|
📰 BREAKING: Smoke macOS ARM64 is now investigating this pull request. Sources say the story is developing... |
|
🎬 THE END — Smoke Claude MISSION: ACCOMPLISHED! The hero saves the day! ✨ |
|
📰 DEVELOPING STORY: Smoke macOS ARM64 reports failed. Our correspondents are investigating the incident... |
|
✅ Smoke Project completed successfully. All project operations validated. |
|
testing required after push |
|
Smoke test §22204680139 results for
Status:
|
There was a problem hiding this comment.
Simple, correct fix for cross-platform compatibility. The two changes (${HOME} and $(whoami)) are minimal and appropriate.
📰 BREAKING: Report filed by Smoke Copilot for issue #16970
|
📰 VERDICT: Smoke Copilot has concluded. All systems operational. This is a developing story. 🎤 |
Smoke Test Results - Run §22204680072Overall: ✅ PASS
|
There was a problem hiding this comment.
💥 Automated smoke test review - all systems nominal!
💥 [THE END] — Illustrated by Smoke Claude for issue #16970
|
Smoke test summary
|
|
📰 BREAKING: Smoke Copilot is now investigating this pull request. Sources say the story is developing... |
Smoke Test Results - Run §22207432521 | PARTIALCore Tests (1-10): PR Review Tests (11-17):
|
There was a problem hiding this comment.
💥 Automated smoke test review - all systems nominal! The changeset files look good and the fix for macOS home directory compatibility is well-documented.
💥 [THE END] — Illustrated by Smoke Claude for issue #16970
On macOS runners, the home directory is /Users/runner, not /home/runner. The hardcoded path causes `mkdir: /home/runner: Operation not supported` on macOS. Also replace hardcoded `runner:runner` with `$(whoami)` for cross-platform compatibility. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
d45defe to
1dccd52
Compare
Docker is unavailable on GHA macOS ARM64 runners (VMs without nested virtualization). Redesign the smoke test to run the agent directly on the host: - Remove network firewall (sandbox.agent: false, strict: false) - Remove Docker-dependent MCP tools (playwright, serena, github) - Skip Docker image downloads on macOS - Skip MCP Gateway on macOS (requires Docker) - Add macOS-specific MCP config with HTTP-only servers (safe-inputs/outputs) - Fix hardcoded /home/runner paths to use $HOME for macOS compatibility - Update test prompt to focus on non-Docker tests (bash, web-fetch, safe-inputs, safe-outputs, Go build, discussion/issue/PR interactions) Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
|
📰 BREAKING: Smoke Copilot is now investigating this pull request. Sources say the story is developing... |
|
✨ The prophecy is fulfilled... Smoke Codex has completed its mystical journey. The stars align. 🌟 |
|
📰 BREAKING: Smoke macOS ARM64 is now investigating this pull request. Sources say the story is developing... |
|
🧪 Smoke Project is now testing project operations... |
|
🎬 THE END — Smoke Claude MISSION: ACCOMPLISHED! The hero saves the day! ✨ |
|
🧪 Smoke Temporary ID is now testing temporary ID functionality... |
|
📰 DEVELOPING STORY: Smoke macOS ARM64 reports failed. Our correspondents are investigating the incident... |
|
✅ Smoke Project completed successfully. All project operations validated. |
|
Smoke test results:
|
|
Smoke test results for PR #16970 (
Overall:
|
There was a problem hiding this comment.
This PR correctly redesigns the macOS ARM64 smoke test to run the Copilot CLI agent directly on the host without Docker. The key changes (disabling firewall sandbox, removing containerized MCP servers, using localhost instead of host.docker.internal) are all appropriate for GHA macOS runners that lack nested virtualization. Left two inline notes on sandbox.agent: false and strict: false for documentation clarity.
📰 BREAKING: Report filed by Smoke Copilot for issue #16970
| sandbox: | ||
| mcp: | ||
| container: "ghcr.io/github/gh-aw-mcpg" | ||
| agent: false |
There was a problem hiding this comment.
Setting agent: false disables the Docker-based firewall and MCP gateway containers. This is the right call for macOS GHA runners where Docker is unavailable, but worth documenting explicitly that the agent runs without network isolation on these runners.
| mcp: | ||
| container: "ghcr.io/github/gh-aw-mcpg" | ||
| agent: false | ||
| strict: false |
There was a problem hiding this comment.
strict: false relaxes validation (action pinning, network config, safe-outputs enforcement). Since this is a macOS-specific smoke test without Docker, this makes sense — just ensuring the constraint relaxation is intentional and documented.
|
📰 VERDICT: Smoke Copilot has concluded. All systems operational. This is a developing story. 🎤 Smoke test complete: 10/11 tests passed. Serena MCP server not available in this workflow context. All other tests (GitHub MCP, gh CLI, Playwright, file write, bash, discussion comment, build, discussion create, haiku dispatch, PR review) passed successfully. |
Smoke Test Results - Claude - Run 22208338012Core Tests: ✅✅✅✅✅✅✅✅✅✅ (10/10 passed)
PR Review Tests (#16970): Overall Status: PARTIAL (all non-skipped tests passed)
|
There was a problem hiding this comment.
💥 Automated smoke test review - all systems nominal! The ${HOME} and $(whoami) fixes look correct and improve cross-platform compatibility. Run §22208338012
💥 [THE END] — Illustrated by Smoke Claude for issue #16970
Summary
install_copilot_cli.sh: use$HOMEinstead of hardcoded/home/runner(macOS uses/Users/runner)runner:runnerwith$(whoami)for cross-platformchownContext
GHA macOS ARM64 runners are VMs (
Apple M1 (Virtual)) without nested virtualization. We tested Docker Desktop (DMG installer, brew cask), colima (vz, qemu, auto-detect), and Apple'scontainertool — none can provide Docker on these runners. The FAQ documents this limitation.Changes
actions/setup/sh/install_copilot_cli.sh— portable$HOMEand$(whoami)docs/src/content/docs/reference/faq.md— new "Platform Support" sectionTest plan
$HOMEfix works on macOS runner (Copilot CLI installs successfully)$HOME=/home/runner,$(whoami)=runner)🤖 Generated with Claude Code