Add generic relation broken hook.

This commit is contained in:
Adam Gandelman 2013-08-20 12:10:36 -07:00
parent 2cb3e8a3e0
commit 7d064697c7
6 changed files with 15 additions and 0 deletions

1
hooks/amqp-relation-broken Symbolic link
View File

@ -0,0 +1 @@
nova_compute_hooks.py

1
hooks/ceph-relation-broken Symbolic link
View File

@ -0,0 +1 @@
nova_compute_hooks.py

View File

@ -0,0 +1 @@
nova_compute_hooks.py

View File

@ -0,0 +1 @@
nova_compute_hooks.py

View File

@ -177,6 +177,16 @@ def ceph_changed():
CONFIGS.write('/etc/nova/nova.conf')
@hooks.hook('amqp-relation-broken',
'ceph-relation-broken',
'cloud-compute-relation-broken',
'image-service-relation-broken',
'shared-db-relation-broken')
@restart_on_change(restart_map())
def relation_broken():
CONFIGS.write_all()
def main():
try:
hooks.execute(sys.argv)

View File

@ -0,0 +1 @@
nova_compute_hooks.py