From 376915e17af04a515f75a438ef43aff4baddf01f Mon Sep 17 00:00:00 2001
From: Ian Wienand <iwienand@redhat.com>
Date: Fri, 9 Aug 2019 16:43:55 +1000
Subject: [PATCH] run_all.sh : add backup playbook

The backup roles have been debugged and are ready to run.

A note is added about having the backup server in a default disabled
state.  This was discussed at an infra meeting where consensus was to
keep it disabled [1].

[1] http://eavesdrop.openstack.org/meetings/infra/2019/infra.2019-06-11-19.01.log.html#l-184

Change-Id: I2a3d2d08a9d1514bf6bdcf15bc5bc95689f3020f
---
 inventory/groups.yaml | 11 +++++++++--
 run_all.sh            |  4 ++++
 2 files changed, 13 insertions(+), 2 deletions(-)

diff --git a/inventory/groups.yaml b/inventory/groups.yaml
index 2eb5172d59..17c9fbee95 100644
--- a/inventory/groups.yaml
+++ b/inventory/groups.yaml
@@ -13,10 +13,17 @@ groups:
   afsadmin: mirror-update[0-9]*.openstack.org
   afsdb: afsdb[0-9]*.open*.org
   ask: ask*.open*.org
+# NOTE: By default we keep the backup-server group empty as an
+# emergency escape hatch if a problem were to propage through
+# production servers.  However, this also means if you add a server to
+# the "backup" group to be backed up, you should uncomment the
+# "backup-server" group for an Ansible pulse so the users & keys are
+# setup on the server(s).  You can submit a follow-on change to revert
+# this at the same time.
   backup:
     - review-dev[0-9]*.open*.org
-  backup-server:
-    - backup[0-9]*.opendev.org
+#  backup-server:
+#    - backup[0-9]*.opendev.org
   cacti: cacti[0-9]*.open*.org
   control-plane-clouds:
     - bridge.openstack.org
diff --git a/run_all.sh b/run_all.sh
index e1617e3205..5f594d9965 100755
--- a/run_all.sh
+++ b/run_all.sh
@@ -117,6 +117,10 @@ start_timer
 timeout -k 2m 30m ansible-playbook -f 50 ${ANSIBLE_PLAYBOOKS}/service-mirror.yaml
 send_timer mirror
 
+start_timer
+timeout -k 2m 30m ansible-playbook -f 50 ${ANSIBLE_PLAYBOOKS}/service-backup.yaml
+send_timer backup
+
 start_timer
 timeout -k 2m 30m ansible-playbook -f 50 ${ANSIBLE_PLAYBOOKS}/service-registry.yaml
 send_timer registry