From 526ff5d46240dea3670ad3910f9a4c875040505b Mon Sep 17 00:00:00 2001 From: noasaunders219 <117283483+noasaunders219@users.noreply.github.com> Date: Thu, 5 Dec 2024 12:05:41 +0200 Subject: [PATCH 1/3] added scheduling --- .../aks/schemas/ocean-virtualNodeGroup.yaml | 2 ++ .../schemas/virtualNodeGroup-scheduling.yaml | 23 +++++++++++++++++++ 2 files changed, 25 insertions(+) create mode 100644 api/services/ocean/aks/schemas/virtualNodeGroup-scheduling.yaml diff --git a/api/services/ocean/aks/schemas/ocean-virtualNodeGroup.yaml b/api/services/ocean/aks/schemas/ocean-virtualNodeGroup.yaml index e0b0f46c3..dd82ed2dd 100644 --- a/api/services/ocean/aks/schemas/ocean-virtualNodeGroup.yaml +++ b/api/services/ocean/aks/schemas/ocean-virtualNodeGroup.yaml @@ -93,6 +93,8 @@ properties: A maximum of 10 unique key-value pairs for VM tags in the virtual node group. vmSizes: $ref: "../schemas/ocean-vmSizes.yaml" + scheduling: + $ref: "../schemas/virtualNodeGroup-scheduling.yaml" createdAt: type: string readOnly: true diff --git a/api/services/ocean/aks/schemas/virtualNodeGroup-scheduling.yaml b/api/services/ocean/aks/schemas/virtualNodeGroup-scheduling.yaml new file mode 100644 index 000000000..d3bbbe889 --- /dev/null +++ b/api/services/ocean/aks/schemas/virtualNodeGroup-scheduling.yaml @@ -0,0 +1,23 @@ +type: object +description: > + An object used to specify times when the virtual node group will turn off all its node pools. Once the shutdown time will be over, the virtual node group will return to its previous state. +title: Ocean VNG AKS Scheduling +properties: + shutdownHours: + type: object + description: > + An object used to specify times that the nodes in the virtual node group will be stopped. + title: Shutdown Hours + properties: + timeWindows: + type: array + description: > + The times that the shutdown hours will apply. Required if isEnabled is true. + items: + type: string + example: "Sat:08:00-Sun:08:00" + isEnabled: + type: boolean + example: true + description: > + Flag to enable or disable the shutdown hours mechanism. When False, the mechanism is deactivated, and the virtual node gorup remains in its current state. \ No newline at end of file From 2096088d304470188d3011f471c9614098e4ab8b Mon Sep 17 00:00:00 2001 From: noasaunders219 <117283483+noasaunders219@users.noreply.github.com> Date: Sun, 8 Dec 2024 14:17:17 +0200 Subject: [PATCH 2/3] added scheduling --- .../ocean/aks/schemas/create/ocean-virtualNodeGroup.yaml | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/api/services/ocean/aks/schemas/create/ocean-virtualNodeGroup.yaml b/api/services/ocean/aks/schemas/create/ocean-virtualNodeGroup.yaml index e47e9ad32..2c72f2479 100644 --- a/api/services/ocean/aks/schemas/create/ocean-virtualNodeGroup.yaml +++ b/api/services/ocean/aks/schemas/create/ocean-virtualNodeGroup.yaml @@ -91,4 +91,6 @@ properties: description: | A maximum of 10 unique key-value pairs for VM tags in the virtual node group. vmSizes: - $ref: "../../schemas/ocean-vmSizes.yaml" \ No newline at end of file + $ref: "../../schemas/ocean-vmSizes.yaml" + scheduling: + $ref: "../../schemas/virtualNodeGroup-scheduling.yaml" \ No newline at end of file From a73d26b72594cac1ad40bcf7a81ce82026008e70 Mon Sep 17 00:00:00 2001 From: noasaunders219 <117283483+noasaunders219@users.noreply.github.com> Date: Sun, 8 Dec 2024 14:19:45 +0200 Subject: [PATCH 3/3] added scheduling to vng template --- .../aks/schemas/create/ocean-virtualNodeGroupTemplate.yaml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/api/services/ocean/aks/schemas/create/ocean-virtualNodeGroupTemplate.yaml b/api/services/ocean/aks/schemas/create/ocean-virtualNodeGroupTemplate.yaml index c50dd1d58..ea4a0ba84 100644 --- a/api/services/ocean/aks/schemas/create/ocean-virtualNodeGroupTemplate.yaml +++ b/api/services/ocean/aks/schemas/create/ocean-virtualNodeGroupTemplate.yaml @@ -81,3 +81,5 @@ properties: A maximum of 10 unique key-value pairs for VM tags in the virtual node group. vmSizes: $ref: "../../schemas/ocean-vmSizes.yaml" + scheduling: + $ref: "../../schemas/virtualNodeGroup-scheduling.yaml"