org_hosted_runner_custom_images
Creates, updates, deletes, gets or lists an org_hosted_runner_custom_images resource.
Overview
| Name | org_hosted_runner_custom_images |
| Type | Resource |
| Id | github.actions.org_hosted_runner_custom_images |
Fields
The following fields are returned by SELECT queries:
- get_custom_image_for_org
- list_custom_images_for_org
Response
| Name | Datatype | Description |
|---|---|---|
id | integer | The ID of the image. Use this ID for the image parameter when creating a new larger runner. |
name | string | Display name for this image. (example: CustomImage) |
latest_version | string | The latest image version associated with the image. (example: 1.3.0) |
platform | string | The operating system of the image. (example: linux-x64) |
source | string | The image provider. (example: custom) |
state | string | The number of image versions associated with the image. (example: Ready) |
total_versions_size | integer | Total size of all the image versions in GB. |
versions_count | integer | The number of image versions associated with the image. |
Response
| Name | Datatype | Description |
|---|---|---|
images | array | |
total_count | integer |
Methods
The following methods are available for this resource:
| Name | Accessible by | Required Params | Optional Params | Description |
|---|---|---|---|---|
get_custom_image_for_org | select | org, image_definition_id | Get a custom image definition for GitHub Actions Hosted Runners. OAuth tokens and personal access tokens (classic) need the manage_runners:org scope to use this endpoint. | |
list_custom_images_for_org | select | org | List custom images for an organization. OAuth tokens and personal access tokens (classic) need the manage_runners:org scope to use this endpoint. | |
delete_custom_image_from_org | delete | org, image_definition_id | Delete a custom image from the organization. OAuth tokens and personal access tokens (classic) need the manage_runners:org scope to use this endpoint. |
Parameters
Parameters can be passed in the WHERE clause of a query. Check the Methods section to see which parameters are required or optional for each operation.
| Name | Datatype | Description |
|---|---|---|
image_definition_id | integer | Image definition ID of custom image |
org | string | The organization name. The name is not case sensitive. |
SELECT examples
- get_custom_image_for_org
- list_custom_images_for_org
Get a custom image definition for GitHub Actions Hosted Runners.
OAuth tokens and personal access tokens (classic) need the manage_runners:org scope to use this endpoint.
SELECT
id,
name,
latest_version,
platform,
source,
state,
total_versions_size,
versions_count
FROM github.actions.org_hosted_runner_custom_images
WHERE org = '{{ org }}' -- required
AND image_definition_id = '{{ image_definition_id }}' -- required
;
List custom images for an organization.
OAuth tokens and personal access tokens (classic) need the manage_runners:org scope to use this endpoint.
SELECT
images,
total_count
FROM github.actions.org_hosted_runner_custom_images
WHERE org = '{{ org }}' -- required
;
DELETE examples
- delete_custom_image_from_org
Delete a custom image from the organization.
OAuth tokens and personal access tokens (classic) need the manage_runners:org scope to use this endpoint.
DELETE FROM github.actions.org_hosted_runner_custom_images
WHERE org = '{{ org }}' --required
AND image_definition_id = '{{ image_definition_id }}' --required
;