Skip to content

Commit 966392e

Browse files
ShenChen93Copilot
andauthored
update security guide for custom image (#60174)
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
1 parent 48b7036 commit 966392e

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

content/actions/how-tos/manage-runners/larger-runners/use-custom-images.md

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -159,3 +159,11 @@ Once your custom image is ready, you can install it on a new {% data variables.a
159159
```
160160

161161
1. Run your workflow to verify that it completes successfully. The job logs will show the image name and version in the "Set up job" section.
162+
163+
## Security best practices for custom images
164+
165+
To prevent unauthorized changes to your images, follow these best practices.
166+
167+
* **Use dedicated runner groups for image generation.** Runners that generate production images must remain in a dedicated runner group. Do not share runner groups between production and development or test repositories, as anyone with access to a development or test repository could inject malicious code into a production image.
168+
* **Do not allow public repositories to access image-generation runners.** Limit the repositories that can use image-generation runners to only those that require it, and review access regularly.
169+
* **Apply least privilege to repositories.** Avoid granting organization-wide `write` access for repositories that have access to image-generation runners. Because images can be generated from any branch, anyone with write access could create a branch with arbitrary code and trigger image generation.

0 commit comments

Comments
 (0)