diff --git a/playbooks/manual/staging-sync/db-sync.yml b/playbooks/manual/staging-sync/db-sync.yml index 8aa97914d8..bb5c377951 100644 --- a/playbooks/manual/staging-sync/db-sync.yml +++ b/playbooks/manual/staging-sync/db-sync.yml @@ -38,7 +38,7 @@ flat: yes - name: bring staging services down - hosts: "{{ server }}" + hosts: "{{ server or batcave }}" user: root any_errors_fatal: false vars_files: @@ -50,6 +50,7 @@ tasks: - service: name=httpd state=stopped + when: server is defined - name: drop and re-create the staging db entirely hosts: "{{ dbhost }}.stg.iad2.fedoraproject.org" @@ -80,7 +81,7 @@ shell: cat /var/tmp/{{ db }}.dump | psql {{ db }} - name: bring staging services up - hosts: "{{ server }}" + hosts: "{{ server or batcave }}" user: root any_errors_fatal: false vars_files: @@ -92,6 +93,7 @@ tasks: - service: name=httpd state=started + when: server is defined - name: Remove the prod db dump now that we are done hosts: "{{ dbhost }}.iad2.fedoraproject.org"