vip-manager 2.8 now speaks Patroni’s REST API
vip-manager 2.8.0, released by Cybertec, adds direct integration with the Patroni REST API. Previously, the tool—a staple for virtual IP (VIP) management in PostgreSQL high-availability clusters—relied on etcd or Consul as the source of truth for leader election state. The new version lets operators point vip-manager straight at Patroni itself, dropping a layer of middleware from the stack.
This also widens the tool’s use cases. Because the REST API exposes cluster member state, vip-manager can now manage virtual IPs not only for the primary but also for replicas, which opens up flexible routing schemes beyond simple leader failover.
Simpler setup, fewer moving parts
The integration removes the need for separate DCS configuration when Patroni is running locally. Defaults cover the common case: with Patroni reachable at localhost, you can skip explicit dcs-endpoints settings entirely.
Operationally, the change means fewer dependencies to align during cluster provisioning. For existing users, the historical dcs prefix remains in the CLI flags (such as --dcs-type) for compatibility, even though Patroni—not a distributed consensus store—is now answering the queries.
Configuring a VIP for the primary
To manage a virtual IP for the active primary, you configure vip-manager to check Patroni’s leader endpoint:
|
1 2 |
vip-manager --ip=10.0.0.42 --interface=eth0 \ --trigger-key="/leader" --trigger-value=200 --dcs-type=patroni |
Breaking down the options:
--ip=10.0.0.42: the virtual IP address to manage--interface=eth0: the network interface that will carry the VIP--trigger-key="/leader": the Patroni REST API endpoint checked to determine leadership--trigger-value=200: the HTTP status code interpreted as “this node is the leader”--dcs-type=patroni: select Patroni as the source of truth
If Patroni responds with the expected status for the leader endpoint, vip-manager assigns the virtual IP to the local host.
Pointing a VIP at a replica
The same mechanism can target nodes that are not the primary. For example, to direct a virtual IP to a replica, issue:
|
1 2 |
vip-manager --ip=10.0.0.42 --interface=eth0 \ --trigger-key="/asynchronous" --trigger-value=200 --dcs-type=patroni |
With Patroni running on the same host, no dcs-endpoints value is required.
vip-manager is an open-source project; contributions are accepted via pull requests, and bug reports and questions can be filed in the issue tracker or discussions area on GitHub.



