From 82243829d07eb6a7a812a94adac192c27d6e0e01 Mon Sep 17 00:00:00 2001 From: Adam <103067949+AdamL-Microsoft@users.noreply.github.com> Date: Mon, 23 Oct 2023 14:56:55 -0700 Subject: [PATCH] Updating Ubuntu 20.04 to Ubuntu 22.04 for OneFuzz defaults (#3570) --- docs/getting-started.md | 4 ++-- docs/supported-platforms.md | 4 ++-- docs/webhook_events.md | 8 ++++---- src/ApiService/ApiService/onefuzzlib/ImageReference.cs | 2 +- src/pytypes/extra/generate-docs.py | 2 +- src/pytypes/onefuzztypes/models.py | 2 +- src/pytypes/tests/test_models.py | 6 +++--- 7 files changed, 14 insertions(+), 14 deletions(-) diff --git a/docs/getting-started.md b/docs/getting-started.md index db7eb1dc32..ed9534f020 100644 --- a/docs/getting-started.md +++ b/docs/getting-started.md @@ -126,14 +126,14 @@ $ onefuzz pools create my-pool linux --query pool_id "9e779388-a9c2-4934-9fa2-6ed6f6a7792a" ``` -To create a managed scaleset of Ubuntu 20.04 VMs using a [general purpose +To create a managed scaleset of Ubuntu 22.04 VMs using a [general purpose Azure VM](https://docs.microsoft.com/en-us/azure/virtual-machines/sizes) that belongs to the pool: ```console $ onefuzz scalesets create my-pool $VM_COUNT { - "image": "Canonical:0001-com-ubuntu-server-focal:20_04-lts:latest", + "image": "Canonical:0001-com-ubuntu-server-jammy:22_04-lts:latest", "pool_name": "my-pool", "region": "eastus", "scaleset_id": "eb1e9602-4acf-40b8-9216-a5d598d27195", diff --git a/docs/supported-platforms.md b/docs/supported-platforms.md index b311301d1f..7fa99d3880 100644 --- a/docs/supported-platforms.md +++ b/docs/supported-platforms.md @@ -15,8 +15,8 @@ OneFuzz deploys targets into Azure Virtual Machine Scale Sets for fuzzing (and supporting tasks). OneFuzz permits arbitrary choice of VM SKU and OS Image, including custom images. We continuously test on Window 11 Pro x64 (using the Azure OS image URN `MicrosoftWindowsDesktop:Windows-11:win11-22h2-pro:latest`) -and Ubuntu 20.04 LTS x64 (using the Azure OS image URN -`Canonical:0001-com-ubuntu-server-focal:20_04-lts:latest`). +and Ubuntu 22.04 LTS x64 (using the Azure OS image URN +`Canonical:0001-com-ubuntu-server-jammy:22_04-lts:latest`). ### LibFuzzer Compilation diff --git a/docs/webhook_events.md b/docs/webhook_events.md index 16f9b6a20f..5103b16b33 100644 --- a/docs/webhook_events.md +++ b/docs/webhook_events.md @@ -725,7 +725,7 @@ If webhook is set to have Event Grid message format then the payload will look a "allowed_aad_tenants": [ "00000000-0000-0000-0000-000000000000" ], - "default_linux_vm_image": "Canonical:0001-com-ubuntu-server-focal:20_04-lts:latest", + "default_linux_vm_image": "Canonical:0001-com-ubuntu-server-jammy:22_04-lts:latest", "default_windows_vm_image": "MicrosoftWindowsDesktop:Windows-11:win11-22h2-pro:latest", "network_config": { "address_space": "10.0.0.0/8", @@ -868,7 +868,7 @@ If webhook is set to have Event Grid message format then the payload will look a "type": "object" }, "default_linux_vm_image": { - "default": "Canonical:0001-com-ubuntu-server-focal:20_04-lts:latest", + "default": "Canonical:0001-com-ubuntu-server-jammy:22_04-lts:latest", "title": "Default Linux Vm Image", "type": "string" }, @@ -2576,7 +2576,7 @@ If webhook is set to have Event Grid message format then the payload will look a ```json { - "image": "Canonical:0001-com-ubuntu-server-focal:20_04-lts:latest", + "image": "Canonical:0001-com-ubuntu-server-jammy:22_04-lts:latest", "pool_name": "example", "region": "eastus", "scaleset_id": "example-000", @@ -6215,7 +6215,7 @@ If webhook is set to have Event Grid message format then the payload will look a "type": "object" }, "default_linux_vm_image": { - "default": "Canonical:0001-com-ubuntu-server-focal:20_04-lts:latest", + "default": "Canonical:0001-com-ubuntu-server-jammy:22_04-lts:latest", "title": "Default Linux Vm Image", "type": "string" }, diff --git a/src/ApiService/ApiService/onefuzzlib/ImageReference.cs b/src/ApiService/ApiService/onefuzzlib/ImageReference.cs index 3403d75697..e6118a1864 100644 --- a/src/ApiService/ApiService/onefuzzlib/ImageReference.cs +++ b/src/ApiService/ApiService/onefuzzlib/ImageReference.cs @@ -14,7 +14,7 @@ namespace Microsoft.OneFuzz.Service; public static class DefaultImages { public static readonly ImageReference Windows = ImageReference.MustParse("MicrosoftWindowsDesktop:Windows-11:win11-22h2-pro:latest"); - public static readonly ImageReference Linux = ImageReference.MustParse("Canonical:0001-com-ubuntu-server-focal:20_04-lts:latest"); + public static readonly ImageReference Linux = ImageReference.MustParse("Canonical:0001-com-ubuntu-server-jammy:22_04-lts:latest"); } [JsonConverter(typeof(Converter))] diff --git a/src/pytypes/extra/generate-docs.py b/src/pytypes/extra/generate-docs.py index 50dfc0ea51..5e3f505679 100755 --- a/src/pytypes/extra/generate-docs.py +++ b/src/pytypes/extra/generate-docs.py @@ -197,7 +197,7 @@ def main() -> None: scaleset_id="example-000", pool_name=PoolName("example"), vm_sku="Standard_D2s_v3", - image="Canonical:0001-com-ubuntu-server-focal:20_04-lts:latest", + image="Canonical:0001-com-ubuntu-server-jammy:22_04-lts:latest", region=Region("eastus"), size=10, ), diff --git a/src/pytypes/onefuzztypes/models.py b/src/pytypes/onefuzztypes/models.py index 53d8fa84a1..746c528c1c 100644 --- a/src/pytypes/onefuzztypes/models.py +++ b/src/pytypes/onefuzztypes/models.py @@ -846,7 +846,7 @@ class InstanceConfig(BaseModel): default="MicrosoftWindowsDesktop:Windows-11:win11-22h2-pro:latest" ) default_linux_vm_image: str = Field( - default="Canonical:0001-com-ubuntu-server-focal:20_04-lts:latest" + default="Canonical:0001-com-ubuntu-server-jammy:22_04-lts:latest" ) proxy_vm_sku: str = Field(default="Standard_B2s") api_access_rules: Optional[Dict[Endpoint, ApiAccessRule]] = None diff --git a/src/pytypes/tests/test_models.py b/src/pytypes/tests/test_models.py index 04902f6806..36d6a64fa0 100755 --- a/src/pytypes/tests/test_models.py +++ b/src/pytypes/tests/test_models.py @@ -57,7 +57,7 @@ def test_scaleset_size(self) -> None: scaleset_id="test-pool-000", pool_name=PoolName("test-pool"), vm_sku="Standard_D2ds_v4", - image="Canonical:0001-com-ubuntu-server-focal:20_04-lts:latest", + image="Canonical:0001-com-ubuntu-server-jammy:22_04-lts:latest", region=Region("westus2"), size=-1, spot_instances=False, @@ -67,7 +67,7 @@ def test_scaleset_size(self) -> None: scaleset_id="test-pool-000", pool_name=PoolName("test-pool"), vm_sku="Standard_D2ds_v4", - image="Canonical:0001-com-ubuntu-server-focal:20_04-lts:latest", + image="Canonical:0001-com-ubuntu-server-jammy:22_04-lts:latest", region=Region("westus2"), size=0, spot_instances=False, @@ -78,7 +78,7 @@ def test_scaleset_size(self) -> None: scaleset_id="test-pool-000", pool_name=PoolName("test-pool"), vm_sku="Standard_D2ds_v4", - image="Canonical:0001-com-ubuntu-server-focal:20_04-lts:latest", + image="Canonical:0001-com-ubuntu-server-jammy:22_04-lts:latest", region=Region("westus2"), size=80, spot_instances=False,