Provide a one-click method to start keepalived using docker-compose.
- chk_svc.sh中的端口,修改成你需要守护的端口,默认为443。同时请chmod +x chk_svc.sh,赋予脚本执行权限。
- keepalived.conf.master及keepalived.conf.backup中,修改interface,将网卡名称和你本机的业务网卡匹配。按需修改auth_pass密码。
- In the
chk_svc.sh
file, modify the port to the one you wish to monitor. The default is 443. Additionally, executechmod +x chk_svc.sh
to grant execution permissions to the script. - In the
keepalived.conf.master
andkeepalived.conf.backup
files, adjust theinterface
parameter to match the network interface on your machine. Modify theauth_pass
password as needed.