No description
- Go 90.3%
- Shell 9.7%
|
|
||
|---|---|---|
| cmd/vipd | ||
| internal | ||
| scripts | ||
| vendor | ||
| .gitignore | ||
| go.mod | ||
| go.sum | ||
| README.md | ||
vipd
vipd is a small FreeBSD-oriented daemon that elects a single leader using etcd
and makes a floating IPv6 VIP reachable by:
- adding the VIP as an IPv6 alias inside a target jail, and
- installing a
/128host route towards the active jail interface.
It can optionally start/stop MaxScale inside the jail together with VIP ownership.
Config
Example (matches modules/vipd/files/vipd.profile.yaml.tmpl in esys-infra):
cluster_name: mgmttest-galera
etcd_endpoints:
- "http://[fda3:397e:3f51:100::1000]:2379"
- "http://[fda3:397e:3f51:100::2000]:2379"
- "http://[fda3:397e:3f51:100::3000]:2379"
jail: mariadb01
jail_iface: vnet0
host_iface: p0a_mariadb01
vip: "fda3:397e:3f51:100::3306:ff"
manage_maxscale: true
health_interval: "3s"
session_ttl: "10s"
require_primary: true
require_synced: true
min_cluster_size: 2
frr:
mode: "kernel_redistribute"
vip_prefixlen: 128
Run
go build ./cmd/vipd
sudo ./vipd -config /usr/local/etc/vipd/mariadb01.yaml -profile mariadb01
FreeBSD port (Poudriere / overlay)
The esys-overlay port sysutils/vipd fetches main.tar.gz from Forgejo and
expects a vendored tree (vendor/modules.txt) in that archive. Before you
cut a new distfile:
go mod vendor
The rc script for multi-profile operation lives in scripts/rc.d.vipd; the
esys-infra vipd module installs an equivalent file under
/usr/local/etc/rc.d/vipd on managed hosts.