init: Provide a service file for charon-systemd using swanctl
This commit is contained in:
@@ -1566,6 +1566,7 @@ AC_CONFIG_FILES([
|
|||||||
man/Makefile
|
man/Makefile
|
||||||
init/Makefile
|
init/Makefile
|
||||||
init/systemd/Makefile
|
init/systemd/Makefile
|
||||||
|
init/systemd-swanctl/Makefile
|
||||||
src/Makefile
|
src/Makefile
|
||||||
src/include/Makefile
|
src/include/Makefile
|
||||||
src/libstrongswan/Makefile
|
src/libstrongswan/Makefile
|
||||||
|
|||||||
@@ -4,3 +4,9 @@ SUBDIRS =
|
|||||||
if USE_LEGACY_SYSTEMD
|
if USE_LEGACY_SYSTEMD
|
||||||
SUBDIRS += systemd
|
SUBDIRS += systemd
|
||||||
endif
|
endif
|
||||||
|
|
||||||
|
if USE_SYSTEMD
|
||||||
|
if USE_SWANCTL
|
||||||
|
SUBDIRS += systemd-swanctl
|
||||||
|
endif
|
||||||
|
endif
|
||||||
|
|||||||
@@ -0,0 +1 @@
|
|||||||
|
strongswan-swanctl.service
|
||||||
@@ -0,0 +1,11 @@
|
|||||||
|
|
||||||
|
EXTRA_DIST = strongswan-swanctl.service.in
|
||||||
|
CLEANFILES = strongswan-swanctl.service
|
||||||
|
|
||||||
|
systemdsystemunit_DATA = strongswan-swanctl.service
|
||||||
|
|
||||||
|
strongswan-swanctl.service : strongswan-swanctl.service.in
|
||||||
|
$(AM_V_GEN) \
|
||||||
|
sed \
|
||||||
|
-e "s:@SBINDIR@:$(sbindir):" \
|
||||||
|
$(srcdir)/$@.in > $@
|
||||||
@@ -0,0 +1,9 @@
|
|||||||
|
[Unit]
|
||||||
|
Description=strongSwan IPsec IKEv1/IKEv2 daemon using swanctl
|
||||||
|
After=network.target
|
||||||
|
|
||||||
|
[Service]
|
||||||
|
Type=notify
|
||||||
|
ExecStart=@SBINDIR@/charon-systemd
|
||||||
|
ExecStartPost=@SBINDIR@/swanctl --load-all --noprompt
|
||||||
|
ExecReload=@SBINDIR@/swanctl --reload
|
||||||
Reference in New Issue
Block a user