strongswan: trigger reload when interfaces are specified
Fixes #20848 Add interface triggers if interfaces to listen to are specified in `/etc/config/ipsec`. This fixes the "running with no instances" scenario after rebooting a router. Signed-off-by: Joel Low <joel@joelsplace.sg>
This commit is contained in:
parent
08746a1942
commit
f2d209e4ff
2 changed files with 11 additions and 1 deletions
|
@ -9,7 +9,7 @@ include $(TOPDIR)/rules.mk
|
||||||
|
|
||||||
PKG_NAME:=strongswan
|
PKG_NAME:=strongswan
|
||||||
PKG_VERSION:=5.9.13
|
PKG_VERSION:=5.9.13
|
||||||
PKG_RELEASE:=1
|
PKG_RELEASE:=2
|
||||||
|
|
||||||
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2
|
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2
|
||||||
PKG_SOURCE_URL:=https://download.strongswan.org/ https://download2.strongswan.org/
|
PKG_SOURCE_URL:=https://download.strongswan.org/ https://download2.strongswan.org/
|
||||||
|
|
|
@ -712,6 +712,16 @@ stop_service() {
|
||||||
service_triggers() {
|
service_triggers() {
|
||||||
procd_add_reload_trigger "ipsec"
|
procd_add_reload_trigger "ipsec"
|
||||||
config load "ipsec"
|
config load "ipsec"
|
||||||
|
|
||||||
|
config_foreach service_trigger_ipsec ipsec
|
||||||
|
}
|
||||||
|
|
||||||
|
service_trigger_ipsec() {
|
||||||
|
local interface interface_list
|
||||||
|
config_list_foreach "$1" interface append_var interface_list
|
||||||
|
for interface in $interface_list; do
|
||||||
|
procd_add_reload_interface_trigger $interface
|
||||||
|
done
|
||||||
}
|
}
|
||||||
|
|
||||||
start_service() {
|
start_service() {
|
||||||
|
|
Loading…
Reference in a new issue