Skip to content

Commit

Permalink
Issue #SB-4536 fix: delegate task to swarm manager
Browse files Browse the repository at this point in the history
  • Loading branch information
rjshrjndrn committed Jun 13, 2018
1 parent fe95687 commit d0c7817
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions ansible/roles/prometheus-backup/tasks/main.yml
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
- name: ensure prometheus is stopped before backup
shell: "docker service scale monitor_prometheus=0"
delegate_to: swarm-bootstrap-manager
run_once: true
delegate_to: "{{group['swarm-bootstrap-manager'][0]}}"

- name: Starting Prometheus backup
block:
Expand All @@ -24,8 +23,7 @@
always:
- name: ensure prometheus is started after backup
shell: "docker service scale monitor_prometheus=1"
delegate_to: swarm-bootstrap-manager
run_once: true
delegate_to: "{{group['swarm-bootstrap-manager'][0]}}"

- name: Ensure azure blob storage container exists
command: az storage container create --name {{ prometheus_backup_azure_container_name }}
Expand Down

0 comments on commit d0c7817

Please sign in to comment.