File tree Expand file tree Collapse file tree 2 files changed +23
-0
lines changed
Expand file tree Collapse file tree 2 files changed +23
-0
lines changed Original file line number Diff line number Diff line change @@ -56,6 +56,7 @@ define Package/ns-ha/install
5656 $(INSTALL_DATA ) ./files/600-qosify $(1 ) /etc/hotplug.d/keepalived
5757 $(INSTALL_DATA ) ./files/600-snort $(1 ) /etc/hotplug.d/keepalived
5858 $(INSTALL_DATA ) ./files/600-ipsec $(1 ) /etc/hotplug.d/keepalived
59+ $(INSTALL_DATA ) ./files/600-acme $(1 ) /etc/hotplug.d/keepalived
5960 $(INSTALL_DATA ) ./files/700-nginx $(1 ) /etc/hotplug.d/keepalived
6061 $(INSTALL_DATA ) ./files/800-adblock $(1 ) /etc/hotplug.d/keepalived
6162 $(INSTALL_DATA ) ./files/800-banip $(1 ) /etc/hotplug.d/keepalived
Original file line number Diff line number Diff line change 1+ #! /bin/sh
2+
3+ . /lib/functions/keepalived/hotplug.sh
4+ . /lib/functions/keepalived/ns.sh
5+
6+ set_service_name acme
7+
8+ set_restart_if_master
9+ set_stop_if_backup
10+
11+ add_sync_file /etc/config/acme
12+
13+ if [ " $ACTION " == " NOTIFY_SYNC" ]; then
14+ home=$( get_rsync_user_home)
15+ rsync -avr $home /etc/acme/ /etc/acme/
16+ elif [ " $ACTION " == " NOTIFY_BACKUP" ]; then
17+ update_cron " disable" " acme"
18+ elif [ " $ACTION " == " NOTIFY_MASTER" ]; then
19+ update_cron " enable" " acme"
20+ fi
21+
22+ keepalived_hotplug
You can’t perform that action at this time.
0 commit comments