Write restart flags to restart services only when necessary
authorJiri Stransky <jistr@redhat.com>
Fri, 19 Aug 2016 13:17:59 +0000 (15:17 +0200)
committerJiri Stransky <jistr@redhat.com>
Tue, 30 Aug 2016 09:19:53 +0000 (11:19 +0200)
commitda4bcee4d65cf2e0d48eab03a4a9582e3806238e
treed678f042c861e1529862bebd3603c015c011c560
parent66e52a73cf60c8972040929a19b4d56cd7c20737
Write restart flags to restart services only when necessary

Write restart flag file for services managed by Pacemaker into
/var/lib/tripleo/pacemaker-restarts directory. The name of the file must
match the name of the clone resource defined in pacemaker. The
post-puppet restart script will restart each service having a restart
flag file and remove those files.

This approach focuses on $pacemaker_master only (we don't want to
restart the pacemaker services 3 times when we have 3 controllers), so
it relies on the assumption that we're making the matching config
changes across the pacemaker nodes.

Change-Id: I6369ab0c82dbf3c8f21043f8aa9ab810744ddc12
manifests/pacemaker/resource_restart_flag.pp [new file with mode: 0644]
manifests/profile/base/pacemaker.pp
manifests/profile/pacemaker/cinder/backup.pp
manifests/profile/pacemaker/cinder/volume.pp
manifests/profile/pacemaker/database/mysql.pp
manifests/profile/pacemaker/database/redis.pp
manifests/profile/pacemaker/haproxy.pp
manifests/profile/pacemaker/manila.pp
manifests/profile/pacemaker/rabbitmq.pp