mirror of
https://github.com/pfsense/pfsense.git
synced 2025-10-26 11:38:35 +00:00
More fixes to openvpn to catch up with latest changes.
This commit is contained in:
parent
0349e09d23
commit
aa79a72151
@ -131,11 +131,11 @@ if($_GET['mode'] == "startservice" and !empty($_GET['service'])) {
|
||||
break;
|
||||
case 'openvpn':
|
||||
$vpnmode = $_GET['vpnmode'];
|
||||
if (($vpnmode == "server") or ($vpnmode == "client")) {
|
||||
if (($vpnmode == "server") || ($vpnmode == "client")) {
|
||||
$id = $_GET['id'];
|
||||
if (is_numeric($id)) {
|
||||
$configfile = $g['varetc_path'] . "/openvpn_{$vpnmode}{$id}.conf";
|
||||
mwexec_bg("/usr/local/sbin/openvpn --config $configfile");
|
||||
$configfile = "{$g['varetc_path']}/openvpn/{$vpnmode}{$id}.conf";
|
||||
mwexec_bg("/usr/local/sbin/openvpn --config {$configfile}");
|
||||
}
|
||||
}
|
||||
break;
|
||||
@ -188,7 +188,7 @@ if($_GET['mode'] == "stopservice" && !empty($_GET['service'])) {
|
||||
if (($vpnmode == "server") or ($vpnmode == "client")) {
|
||||
$id = $_GET['id'];
|
||||
if (is_numeric($id)) {
|
||||
$pidfile = $g['varrun_path'] . "/openvpn_{$vpnmode}{$id}.pid";
|
||||
$pidfile = "{$g['varrun_path']}/openvpn_{$vpnmode}{$id}.pid";
|
||||
killbypid($pidfile);
|
||||
}
|
||||
}
|
||||
@ -197,7 +197,7 @@ if($_GET['mode'] == "stopservice" && !empty($_GET['service'])) {
|
||||
stop_service($_GET['service']);
|
||||
break;
|
||||
}
|
||||
$savemsg = sprintf(gettext("%s has been stopped."),$_GET['service']);
|
||||
$savemsg = sprintf(gettext("%s has been stopped."), $_GET['service']);
|
||||
sleep(5);
|
||||
}
|
||||
|
||||
|
||||
Loading…
Reference in New Issue
Block a user