From a452d73605b32aebb18d2ad40b68677a1a3e1fff Mon Sep 17 00:00:00 2001 From: SBeecha_flexera Date: Mon, 6 Apr 2026 11:02:01 +0530 Subject: [PATCH 1/2] Add purchase plan schema for Azure Marketplace VM images purchase plan and update references --- .../create/createStatefulNodeCompute.yaml | 2 ++ .../createStatefulNodePurchasePlan.yaml | 25 +++++++++++++++++++ .../update/updateStatefulNodeCompute.yaml | 2 ++ .../updateStatefulNodePurchasePlan.yaml | 21 ++++++++++++++++ 4 files changed, 50 insertions(+) create mode 100644 api/services/elastigroup/azure/stateful/node/schemas/create/createStatefulNodePurchasePlan.yaml create mode 100644 api/services/elastigroup/azure/stateful/node/schemas/update/updateStatefulNodePurchasePlan.yaml diff --git a/api/services/elastigroup/azure/stateful/node/schemas/create/createStatefulNodeCompute.yaml b/api/services/elastigroup/azure/stateful/node/schemas/create/createStatefulNodeCompute.yaml index 7eca0495..e7b6ab02 100644 --- a/api/services/elastigroup/azure/stateful/node/schemas/create/createStatefulNodeCompute.yaml +++ b/api/services/elastigroup/azure/stateful/node/schemas/create/createStatefulNodeCompute.yaml @@ -750,6 +750,8 @@ properties: * StorageUri is required if the type is unmanaged. * StorageUri must be ‘null’ in case the boot diagnostics type is managed. example: "https://example.blob.core.windows.net/" + purchasePlan: + $ref: "createStatefulNodePurchasePlan.yaml" licenseType: type: string description: | diff --git a/api/services/elastigroup/azure/stateful/node/schemas/create/createStatefulNodePurchasePlan.yaml b/api/services/elastigroup/azure/stateful/node/schemas/create/createStatefulNodePurchasePlan.yaml new file mode 100644 index 00000000..60a717cc --- /dev/null +++ b/api/services/elastigroup/azure/stateful/node/schemas/create/createStatefulNodePurchasePlan.yaml @@ -0,0 +1,25 @@ +type: object +title: Purchase Plan +description: | + Defines the Azure Marketplace purchase plan for the VM image or persisted OS disk. + * Use this when the selected marketplace image, gallery image, or persisted OS disk requires plan metadata. +required: + - publisher + - product + - name +properties: + publisher: + type: string + description: | + Purchase plan publisher. + example: "canonical" + product: + type: string + description: | + Purchase plan product / offer. + example: "0001-com-ubuntu-pro-jammy" + name: + type: string + description: | + Purchase plan name / SKU. + example: "pro-22_04-lts" diff --git a/api/services/elastigroup/azure/stateful/node/schemas/update/updateStatefulNodeCompute.yaml b/api/services/elastigroup/azure/stateful/node/schemas/update/updateStatefulNodeCompute.yaml index 954c5758..19457092 100644 --- a/api/services/elastigroup/azure/stateful/node/schemas/update/updateStatefulNodeCompute.yaml +++ b/api/services/elastigroup/azure/stateful/node/schemas/update/updateStatefulNodeCompute.yaml @@ -718,6 +718,8 @@ properties: description: "The storage URI that is used if type is unmanaged. The storage URI must follow the blob storage URI format (\"https://.blob.core.windows.net/\"). StorageUri is required if the type is unmanaged. StorageUri must be ‘null’ in case the boot diagnostics type is managed" example: "https://example.blob.core.windows.net/" + purchasePlan: + $ref: "updateStatefulNodePurchasePlan.yaml" licenseType: type: string description: | diff --git a/api/services/elastigroup/azure/stateful/node/schemas/update/updateStatefulNodePurchasePlan.yaml b/api/services/elastigroup/azure/stateful/node/schemas/update/updateStatefulNodePurchasePlan.yaml new file mode 100644 index 00000000..681d4865 --- /dev/null +++ b/api/services/elastigroup/azure/stateful/node/schemas/update/updateStatefulNodePurchasePlan.yaml @@ -0,0 +1,21 @@ +type: object +title: Purchase Plan +description: | + Defines the Azure Marketplace purchase plan for the VM image or persisted OS disk. + * On update, each provided field must contain a non-empty value. +properties: + publisher: + type: string + description: | + Purchase plan publisher. + example: "canonical" + product: + type: string + description: | + Purchase plan product / offer. + example: "0001-com-ubuntu-pro-jammy" + name: + type: string + description: | + Purchase plan name / SKU. + example: "pro-22_04-lts" From 5df6d866eb59894a02e64ea864e1acaa7364c951 Mon Sep 17 00:00:00 2001 From: SBeecha_flexera Date: Wed, 22 Apr 2026 12:22:09 +0530 Subject: [PATCH 2/2] Add purchase plan metadata to stateful node schemas for Azure Marketplace --- .../node/schemas/create/createStatefulNodeCompute.yaml | 7 +++++-- .../schemas/create/createStatefulNodePurchasePlan.yaml | 8 ++++++-- .../node/schemas/update/updateStatefulNodeCompute.yaml | 7 +++++-- .../schemas/update/updateStatefulNodePurchasePlan.yaml | 7 ++++++- 4 files changed, 22 insertions(+), 7 deletions(-) diff --git a/api/services/elastigroup/azure/stateful/node/schemas/create/createStatefulNodeCompute.yaml b/api/services/elastigroup/azure/stateful/node/schemas/create/createStatefulNodeCompute.yaml index e7b6ab02..cde2011f 100644 --- a/api/services/elastigroup/azure/stateful/node/schemas/create/createStatefulNodeCompute.yaml +++ b/api/services/elastigroup/azure/stateful/node/schemas/create/createStatefulNodeCompute.yaml @@ -210,6 +210,11 @@ properties: description: "The Spot account ID that connected to the Azure subscription to which the gallery belongs. Relevant only in case of cross-subscription shared galleries. [Read more](https://docs.flexera.com/spot/elastigroup/features-azure/shared-image-galleries) about cross-subscription shared galleries in Elastigroup." type: string example: "act-123456789" + purchasePlan: + description: | + Defines the Azure Marketplace purchase plan metadata for the selected image or osDisk image. + allOf: + - $ref: "createStatefulNodePurchasePlan.yaml" vmName: type: string description: | @@ -750,8 +755,6 @@ properties: * StorageUri is required if the type is unmanaged. * StorageUri must be ‘null’ in case the boot diagnostics type is managed. example: "https://example.blob.core.windows.net/" - purchasePlan: - $ref: "createStatefulNodePurchasePlan.yaml" licenseType: type: string description: | diff --git a/api/services/elastigroup/azure/stateful/node/schemas/create/createStatefulNodePurchasePlan.yaml b/api/services/elastigroup/azure/stateful/node/schemas/create/createStatefulNodePurchasePlan.yaml index 60a717cc..aaeb518a 100644 --- a/api/services/elastigroup/azure/stateful/node/schemas/create/createStatefulNodePurchasePlan.yaml +++ b/api/services/elastigroup/azure/stateful/node/schemas/create/createStatefulNodePurchasePlan.yaml @@ -1,8 +1,8 @@ type: object title: Purchase Plan +additionalProperties: false description: | - Defines the Azure Marketplace purchase plan for the VM image or persisted OS disk. - * Use this when the selected marketplace image, gallery image, or persisted OS disk requires plan metadata. + Defines the Azure Marketplace purchase plan for the VM image. required: - publisher - product @@ -10,16 +10,20 @@ required: properties: publisher: type: string + minLength: 1 description: | Purchase plan publisher. example: "canonical" product: type: string + minLength: 1 description: | Purchase plan product / offer. example: "0001-com-ubuntu-pro-jammy" name: type: string + minLength: 1 description: | Purchase plan name / SKU. + * This value is case-sensitive and must exactly match the Azure plan metadata. example: "pro-22_04-lts" diff --git a/api/services/elastigroup/azure/stateful/node/schemas/update/updateStatefulNodeCompute.yaml b/api/services/elastigroup/azure/stateful/node/schemas/update/updateStatefulNodeCompute.yaml index 19457092..e9e18473 100644 --- a/api/services/elastigroup/azure/stateful/node/schemas/update/updateStatefulNodeCompute.yaml +++ b/api/services/elastigroup/azure/stateful/node/schemas/update/updateStatefulNodeCompute.yaml @@ -202,6 +202,11 @@ properties: description: "The Spot account ID that connected to the Azure subscription to which the gallery belongs. Relevant only in case of cross-subscription shared galleries. [Read more](https://docs.flexera.com/spot/elastigroup/features-azure/shared-image-galleries) about cross-subscription shared galleries in Elastigroup." type: string example: "act-123456789" + purchasePlan: + description: | + Defines the Azure Marketplace purchase plan metadata for the selected image or osDisk image. + allOf: + - $ref: "updateStatefulNodePurchasePlan.yaml" vmName: type: string description: | @@ -718,8 +723,6 @@ properties: description: "The storage URI that is used if type is unmanaged. The storage URI must follow the blob storage URI format (\"https://.blob.core.windows.net/\"). StorageUri is required if the type is unmanaged. StorageUri must be ‘null’ in case the boot diagnostics type is managed" example: "https://example.blob.core.windows.net/" - purchasePlan: - $ref: "updateStatefulNodePurchasePlan.yaml" licenseType: type: string description: | diff --git a/api/services/elastigroup/azure/stateful/node/schemas/update/updateStatefulNodePurchasePlan.yaml b/api/services/elastigroup/azure/stateful/node/schemas/update/updateStatefulNodePurchasePlan.yaml index 681d4865..b3ffaaf3 100644 --- a/api/services/elastigroup/azure/stateful/node/schemas/update/updateStatefulNodePurchasePlan.yaml +++ b/api/services/elastigroup/azure/stateful/node/schemas/update/updateStatefulNodePurchasePlan.yaml @@ -1,21 +1,26 @@ type: object title: Purchase Plan +additionalProperties: false description: | - Defines the Azure Marketplace purchase plan for the VM image or persisted OS disk. + Defines the Azure Marketplace purchase plan for the VM image. * On update, each provided field must contain a non-empty value. properties: publisher: type: string + minLength: 1 description: | Purchase plan publisher. example: "canonical" product: type: string + minLength: 1 description: | Purchase plan product / offer. example: "0001-com-ubuntu-pro-jammy" name: type: string + minLength: 1 description: | Purchase plan name / SKU. + * This value is case-sensitive and must exactly match the Azure plan metadata. example: "pro-22_04-lts"