INNER CODE UNIT · Python
What
LINBIT/linstor-server · scripts/linstor-controller-ha-setup.py:47
What=/dev/drbd/by-res/linstor_db/0
Where=/var/lib/linstor
"""
def reactor_conf(vip=None):
"""The promoter snippet. With a VIP, an ocf:heartbeat:IPaddr2 agent is
started between the mount and the controller, so the address follows the
active controller — the user guide's alternative to pointing every client
at a list of controller IPs."""
services = ['"var-lib-linstor.mount"']
if vip:
address, prefix = vip
services.append('"ocf:heartbeat:IPaddr2 service_ip ip=' + address
+ ' cidr_netmask=' + str(prefix) + '"')
services.append('"linstor-controller.service"')
return ("""[[promoter]]
[promoter.resources.linstor_db]