mirror of
https://github.com/actions/runner-images.git
synced 2025-12-11 11:37:00 +00:00
Add Windows2025 to GenerateResourcesAndImage.ps1 (#11404)
This commit is contained in:
committed by
GitHub
parent
d0ef4c965f
commit
f27bce4030
@@ -98,7 +98,7 @@ Finally, run the `GenerateResourcesAndImage` function, setting the mandatory arg
|
|||||||
- `SubscriptionId` - your Azure Subscription ID;
|
- `SubscriptionId` - your Azure Subscription ID;
|
||||||
- `ResourceGroupName` - the name of the resource group that will be created within your subscription (e.g., "imagegen-test");
|
- `ResourceGroupName` - the name of the resource group that will be created within your subscription (e.g., "imagegen-test");
|
||||||
- `AzureLocation` - the location where resources will be created (e.g., "East US");
|
- `AzureLocation` - the location where resources will be created (e.g., "East US");
|
||||||
- `ImageType` - the type of image to build (we suggest choosing "UbuntuMinimal" here; other valid options are "Windows2019", "Windows2022", "Ubuntu2004", "Ubuntu2204").
|
- `ImageType` - the type of image to build (we suggest choosing "UbuntuMinimal" here; other valid options are "Windows2019", "Windows2022", "Windows2025", "Ubuntu2004", "Ubuntu2204", "Ubuntu2404").
|
||||||
|
|
||||||
This function automatically creates all required Azure resources and initiates the Packer image generation for the selected image type.
|
This function automatically creates all required Azure resources and initiates the Packer image generation for the selected image type.
|
||||||
|
|
||||||
|
|||||||
@@ -3,10 +3,11 @@ $ErrorActionPreference = 'Stop'
|
|||||||
enum ImageType {
|
enum ImageType {
|
||||||
Windows2019 = 1
|
Windows2019 = 1
|
||||||
Windows2022 = 2
|
Windows2022 = 2
|
||||||
Ubuntu2004 = 3
|
Windows2025 = 3
|
||||||
Ubuntu2204 = 4
|
Ubuntu2004 = 4
|
||||||
Ubuntu2404 = 5
|
Ubuntu2204 = 5
|
||||||
UbuntuMinimal = 6
|
Ubuntu2404 = 6
|
||||||
|
UbuntuMinimal = 7
|
||||||
}
|
}
|
||||||
|
|
||||||
Function Get-PackerTemplatePath {
|
Function Get-PackerTemplatePath {
|
||||||
@@ -25,6 +26,9 @@ Function Get-PackerTemplatePath {
|
|||||||
([ImageType]::Windows2022) {
|
([ImageType]::Windows2022) {
|
||||||
$relativeTemplatePath = Join-Path (Join-Path "windows" "templates") "windows-2022.pkr.hcl"
|
$relativeTemplatePath = Join-Path (Join-Path "windows" "templates") "windows-2022.pkr.hcl"
|
||||||
}
|
}
|
||||||
|
([ImageType]::Windows2025) {
|
||||||
|
$relativeTemplatePath = Join-Path (Join-Path "windows" "templates") "windows-2025.pkr.hcl"
|
||||||
|
}
|
||||||
([ImageType]::Ubuntu2004) {
|
([ImageType]::Ubuntu2004) {
|
||||||
$relativeTemplatePath = Join-Path (Join-Path "ubuntu" "templates") "ubuntu-20.04.pkr.hcl"
|
$relativeTemplatePath = Join-Path (Join-Path "ubuntu" "templates") "ubuntu-20.04.pkr.hcl"
|
||||||
}
|
}
|
||||||
@@ -81,7 +85,7 @@ Function GenerateResourcesAndImage {
|
|||||||
.PARAMETER ResourceGroupName
|
.PARAMETER ResourceGroupName
|
||||||
The name of the resource group to create the Azure resources in.
|
The name of the resource group to create the Azure resources in.
|
||||||
.PARAMETER ImageType
|
.PARAMETER ImageType
|
||||||
The type of image to generate. Valid values are: Windows2019, Windows2022, Ubuntu2004, Ubuntu2204, UbuntuMinimal.
|
The type of image to generate. Valid values are: Windows2019, Windows2022, Windows2025, Ubuntu2004, Ubuntu2204, Ubuntu2404, UbuntuMinimal.
|
||||||
.PARAMETER ManagedImageName
|
.PARAMETER ManagedImageName
|
||||||
The name of the managed image to create. The default is "Runner-Image-{{ImageType}}".
|
The name of the managed image to create. The default is "Runner-Image-{{ImageType}}".
|
||||||
.PARAMETER AzureLocation
|
.PARAMETER AzureLocation
|
||||||
|
|||||||
Reference in New Issue
Block a user