summaryrefslogtreecommitdiff
path: root/distbuild/ansible/restart.yaml
blob: 2d16087e52a47a3ad3565843c31f66897c7ca7f9 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
# Restart all Morph instances on a Baserock distbuild network.
#
# This will abort any running builds.
#
# This is an Ansible playbook. Run with:
#
#   ansible-playbook -i distbuild-hosts restart.yaml
#
# You will need a file named 'distbuild-hosts' describing your distbuild
# network.
---

# The order in which the processes are restarted is important! (Sadly).
- hosts: controller
  tasks:
    - name: restart controller processes
      service: name={{ item }} state=restarted
      with_items:
        - morph-controller.service
        - morph-controller-helper.service

- hosts: workers
  tasks:
    - name: restart worker processes
      service: name={{ item }} state=restarted
      with_items:
        - morph-worker.service
        - morph-worker-helper.service