From 31f97d6ccafd4006d20058e12b415fdc947ee776 Mon Sep 17 00:00:00 2001
From: Will Szumski <will@stackhpc.com>
Date: Mon, 18 Jan 2021 15:26:27 +0000
Subject: [PATCH] Do not wait for grafana to start when kolla_action=config

Prior to this change it was not possible to generate the config
before deploying the services as you'd hit:

RUNNING HANDLER [Waiting for grafana to start on first node] *************************
Monday 18 January 2021  15:06:35 +0000 (0:00:00.182)       0:04:39.213 ********
skipping: [sv-h22a8-u19]
skipping: [sv-h22a5-u36]
FAILED - RETRYING: Waiting for grafana to start on first node (10 retries left).

This would never succeed as the service has not yet been deployed.

TrivialFix
Change-Id: I9437a049b24e5e613a7e66add481a8983b84867a
---
 ansible/roles/grafana/handlers/main.yml | 1 +
 1 file changed, 1 insertion(+)

diff --git a/ansible/roles/grafana/handlers/main.yml b/ansible/roles/grafana/handlers/main.yml
index 1cdabf943e..2e13a056a3 100644
--- a/ansible/roles/grafana/handlers/main.yml
+++ b/ansible/roles/grafana/handlers/main.yml
@@ -32,6 +32,7 @@
   retries: 10
   delay: 2
   when:
+    - kolla_action != "config"
     - inventory_hostname == groups[service.group]|first
 
 - name: Restart remaining grafana containers