Add GitHub Copilot CLI to hosted runner images#14045
Draft
salmanmkc wants to merge 1 commit into
Draft
Conversation
Install @github/copilot via npm during image bake for Ubuntu 24.04 and 26.04. This pre-installs the Copilot CLI so agentic workflows using the Copilot engine do not need to install it at runtime, reducing workflow startup time. - Add install-copilot-cli.sh install script - Add Copilot CLI test to CLI.Tools.Tests.ps1 - Add to 24.04 and 26.04 Packer templates
Contributor
There was a problem hiding this comment.
Pull request overview
This PR adds the GitHub Copilot CLI to the Ubuntu 24.04 and 26.04 hosted runner image bake, so workflows can use copilot without installing it at runtime.
Changes:
- Add a new Ubuntu build script to install
@github/copilotglobally vianpm. - Add a Pester test to validate
copilot --versionsucceeds (skipped on Ubuntu 22.04). - Wire the install script into the Ubuntu 24.04 and 26.04 Packer build templates.
Show a summary per file
| File | Description |
|---|---|
| images/ubuntu/templates/build.ubuntu-26_04.pkr.hcl | Adds the Copilot CLI install step to the Ubuntu 26.04 image build script list. |
| images/ubuntu/templates/build.ubuntu-24_04.pkr.hcl | Adds the Copilot CLI install step to the Ubuntu 24.04 image build script list. |
| images/ubuntu/scripts/tests/CLI.Tools.Tests.ps1 | Adds a Pester validation that copilot --version returns exit code 0 (skipped on 22.04). |
| images/ubuntu/scripts/build/install-copilot-cli.sh | New installer that installs the Copilot CLI via npm and invokes the corresponding tests. |
Copilot's findings
- Files reviewed: 4/4 changed files
- Comments generated: 2
Comment on lines
111
to
116
| "${path.root}/../scripts/build/install-cmake.sh", | ||
| "${path.root}/../scripts/build/install-codeql-bundle.sh", | ||
| "${path.root}/../scripts/build/install-awf.sh", | ||
| "${path.root}/../scripts/build/install-copilot-cli.sh", | ||
| "${path.root}/../scripts/build/install-container-tools.sh", | ||
| "${path.root}/../scripts/build/install-dotnetcore-sdk.sh", |
Comment on lines
108
to
114
| "${path.root}/../scripts/build/install-aws-tools.sh", | ||
| "${path.root}/../scripts/build/install-clang.sh", | ||
| "${path.root}/../scripts/build/install-cmake.sh", | ||
| "${path.root}/../scripts/build/install-codeql-bundle.sh", | ||
| "${path.root}/../scripts/build/install-awf.sh", | ||
| "${path.root}/../scripts/build/install-copilot-cli.sh", | ||
| "${path.root}/../scripts/build/install-container-tools.sh", |
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.
Install
@github/copilotvia npm during image bake for Ubuntu 24.04 and 26.04. This pre-installs the Copilot CLI so agentic workflows using the Copilot engine do not need to install it at runtime, reducing workflow startup time.Changes
images/ubuntu/scripts/build/install-copilot-cli.sh— install script usingnpm install -g @github/copilot --ignore-scriptsimages/ubuntu/scripts/tests/CLI.Tools.Tests.ps1— Pester test verifyingcopilot --versionreturns 0images/ubuntu/templates/build.ubuntu-24_04.pkr.hcl— add to 24.04 image buildimages/ubuntu/templates/build.ubuntu-26_04.pkr.hcl— add to 26.04 image build