From 505e6456048c6788a847ffeec572407fd4bb19fc Mon Sep 17 00:00:00 2001 From: Alex Manning Date: Tue, 21 Jul 2026 11:01:03 +0100 Subject: [PATCH 1/2] Docs page for scheduling. --- docs/configuration/18-scheduling.md | 58 +++++++++++++++++++++++++++++ 1 file changed, 58 insertions(+) create mode 100644 docs/configuration/18-scheduling.md diff --git a/docs/configuration/18-scheduling.md b/docs/configuration/18-scheduling.md new file mode 100644 index 00000000..b2aaf03b --- /dev/null +++ b/docs/configuration/18-scheduling.md @@ -0,0 +1,58 @@ +# Scheduling + +Azimuth allows scheduling of the ddeletion of CaaS and Kubernetes clusters. The creating user picks the lifetime of their platform at creation time, and Azimuth will delete the platform when it expires. + +By default, no scheduling features are enabled. Azimuth configuration allows: +* Allowing scheduling, but giving users' free choice as to the lifetime of their platforms. +* Allowing scheduling, and enforcing a maximum lifetime across all platforms. +* Allowing scheduling, and enforcing a maximum lifetime on a per-platform basis using annotations. + +## Enabling scheduling globally +To enable scheduling globally, add azimuth_scheduling_enabled to the appropriate configuration file. +This will enable users creating new platforms to pick a deletion time when the platforms are created. +Existing platforms will be unnafected. + +```yaml title="environments/my-site/inventory/group_vars/all/secrets.yml" +azimuth_scheduling_enabled: true +``` + +## Annotations + +Scheduling is implemented using annotations that are applied to instances of the +`clustertemplates.azimuth.stackhpc.com` and +`clustertypes.caas.azimuth.stackhpc.com` resources for Kubernetes cluster templates, +and CaaS cluster types respectively. +It is not possible to set maximum lifetimes for individual apps inside a kubernetes cluster, +only the cluster itself. + +The annotations is the same for all platform types: + +- `scheduling.azimuth.stackhpc.com/max-lifetime-hours` + A an integer number of hours which will be the maximum lifetime for the platform. + + +!!! warning "No annotations means infinite lifetime" + If no scheduling are present, then that platform has no maximum lifetime. + + +## Built-in platform types + +`azimuth-ops` supports a number of variables that can be used to apply scheduling +to the built-in platform types. + +The following variables allow default lifetimes to be set **for all built-in +platform types**: + +```yaml title="environments/my-site/inventory/group_vars/all/variables.yml" +azimuth_max_platform_duration_hours: 20 +``` + +These can be overridden for specific platform types if required: + +```yaml title="environments/my-site/inventory/group_vars/all/variables.yml" +# The following apply to all Kubernetes cluster templates +azimuth_capi_operator_max_duration_hours: 24 + +# Each CaaS cluster type has specific variables, e.g.: +azimuth_caas_stackhpc_workstation_max_duration_hours: 200 +``` From c991dca2450a34c11b26524fe39d4433c8f4145b Mon Sep 17 00:00:00 2001 From: Alex Manning Date: Tue, 21 Jul 2026 11:16:33 +0100 Subject: [PATCH 2/2] Format using prettier. --- docs/configuration/18-scheduling.md | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/docs/configuration/18-scheduling.md b/docs/configuration/18-scheduling.md index b2aaf03b..7d5e8831 100644 --- a/docs/configuration/18-scheduling.md +++ b/docs/configuration/18-scheduling.md @@ -3,11 +3,13 @@ Azimuth allows scheduling of the ddeletion of CaaS and Kubernetes clusters. The creating user picks the lifetime of their platform at creation time, and Azimuth will delete the platform when it expires. By default, no scheduling features are enabled. Azimuth configuration allows: -* Allowing scheduling, but giving users' free choice as to the lifetime of their platforms. -* Allowing scheduling, and enforcing a maximum lifetime across all platforms. -* Allowing scheduling, and enforcing a maximum lifetime on a per-platform basis using annotations. + +- Allowing scheduling, but giving users' free choice as to the lifetime of their platforms. +- Allowing scheduling, and enforcing a maximum lifetime across all platforms. +- Allowing scheduling, and enforcing a maximum lifetime on a per-platform basis using annotations. ## Enabling scheduling globally + To enable scheduling globally, add azimuth_scheduling_enabled to the appropriate configuration file. This will enable users creating new platforms to pick a deletion time when the platforms are created. Existing platforms will be unnafected. @@ -28,7 +30,7 @@ only the cluster itself. The annotations is the same for all platform types: - `scheduling.azimuth.stackhpc.com/max-lifetime-hours` - A an integer number of hours which will be the maximum lifetime for the platform. + A an integer number of hours which will be the maximum lifetime for the platform. !!! warning "No annotations means infinite lifetime"