#!/bin/sh # Start or stop strongswan # $FreeBSD: head/security/strongswan/files/strongswan.in 354114 2014-05-15 12:47:20Z pi $ # PROVIDE: strongswan # REQUIRE: DAEMON # BEFORE: LOGIN # KEYWORD: shutdown command="%%PREFIX%%/sbin/ipsec" . /etc/rc.subr name="strongswan" rcvar=${name}_enable extra_commands="reload statusall" load_rc_config $name start_cmd="strongswan_command start" stop_cmd="strongswan_command stop" restart_cmd="strongswan_command restart" status_cmd="strongswan_command status" reload_cmd="strongswan_command reload" statusall_cmd="strongswan_command statusall" strongswan_command() { $command ${rc_arg} } run_rc_command "$1"