From 2658297b2c8e85531053c60399e89b71808117d7 Mon Sep 17 00:00:00 2001 From: "Pavel Tumik @ GitPod" <18602811+sagor999@users.noreply.github.com> Date: Wed, 21 Sep 2022 13:02:00 -0700 Subject: [PATCH] fix prometheus rule for workspaces --- .../observability/mixins/workspace/rules/workspaces.yaml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/operations/observability/mixins/workspace/rules/workspaces.yaml b/operations/observability/mixins/workspace/rules/workspaces.yaml index 384514b1c27de8..95ad3731fdfe43 100644 --- a/operations/observability/mixins/workspace/rules/workspaces.yaml +++ b/operations/observability/mixins/workspace/rules/workspaces.yaml @@ -27,7 +27,7 @@ spec: annotations: runbook_url: https://github.com/gitpod-io/runbooks/blob/main/runbooks/GitpodWorkspaceStuckOnStarting.md summary: 5 or more workspaces are stuck on starting - description: "{{ printf '%.2f' $value }} regular workspaces are stuck on starting for more than 20 minutes. Current status: {{ $labels.reason }}" + description: '{{ printf "%.2f" $value }} regular workspaces are stuck on starting for more than 20 minutes. Current status: {{ $labels.reason }}' expr: | count( kube_pod_container_status_waiting_reason * on(pod) group_left kube_pod_labels{component="workspace", workspace_type="regular"} @@ -40,7 +40,7 @@ spec: annotations: runbook_url: https://github.com/gitpod-io/runbooks/blob/main/runbooks/GitpodWorkspaceStuckOnStopping.md summary: 5 or more workspaces are stuck on stopping - description: "{{ printf '%.2f' $value }} {{ $labels.workspace_type }} workspaces are stuck on stopping for more than 20 minutes." + description: '{{ printf "%.2f" $value }} {{ $labels.workspace_type }} workspaces are stuck on stopping for more than 20 minutes.' expr: | sum( gitpod_ws_manager_workspace_phase_total{type="REGULAR", phase="STOPPING"}