|
|
|
@ -184,6 +184,7 @@ $stats = json_decode(implode("", $output), true);
|
|
|
|
|
unset($output);
|
|
|
|
|
|
|
|
|
|
//Check if passenger enabled
|
|
|
|
|
$ruby_enabled = false;
|
|
|
|
|
$passenger_state = "disabled";
|
|
|
|
|
exec(HESTIA_CMD . "v-ext-modules state passenger_manager json", $output, $return_var);
|
|
|
|
|
$check_passenger_enabled = json_decode(implode("", $output), true);
|
|
|
|
@ -202,6 +203,10 @@ if (($return_var == 0) && (!empty($check_passenger_enabled)) && ($check_passenge
|
|
|
|
|
unset($output);
|
|
|
|
|
if ($return_var != 0){
|
|
|
|
|
$passenger_state = "disabled";
|
|
|
|
|
} else {
|
|
|
|
|
if (trim($domain_ruby[0]["RUBY"]) != ""){
|
|
|
|
|
$ruby_enabled = true;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
@ -220,6 +225,7 @@ if (!empty($_POST["save"])) {
|
|
|
|
|
$v_newip_public = "";
|
|
|
|
|
|
|
|
|
|
$changed_ruby = false;
|
|
|
|
|
$ruby_tpl = "default";
|
|
|
|
|
|
|
|
|
|
// Save ruby setting for domain
|
|
|
|
|
if (!empty($_POST["v_passenger_enabled"])){
|
|
|
|
@ -231,6 +237,7 @@ if (!empty($_POST["save"])) {
|
|
|
|
|
$restart_proxy = "yes";
|
|
|
|
|
unset($output);
|
|
|
|
|
$changed_ruby = true;
|
|
|
|
|
$ruby_tpl = "passenger";
|
|
|
|
|
}
|
|
|
|
|
} else {
|
|
|
|
|
if ($passenger_state == "enabled"){
|
|
|
|
@ -251,7 +258,7 @@ if (!empty($_POST["save"])) {
|
|
|
|
|
" " .
|
|
|
|
|
quoteshellarg($v_domain) .
|
|
|
|
|
" " .
|
|
|
|
|
"passenger",
|
|
|
|
|
quoteshellarg($ruby_tpl),
|
|
|
|
|
$output, $return_var);
|
|
|
|
|
check_return_code($return_var, $output);
|
|
|
|
|
$restart_web = "yes";
|
|
|
|
@ -448,6 +455,7 @@ if (!empty($_POST["save"])) {
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
// Delete proxy support
|
|
|
|
|
if (!$ruby_enabled) {
|
|
|
|
|
if (
|
|
|
|
|
!empty($_SESSION["PROXY_SYSTEM"]) &&
|
|
|
|
|
!empty($v_proxy) &&
|
|
|
|
@ -553,6 +561,7 @@ if (!empty($_POST["save"])) {
|
|
|
|
|
unset($output);
|
|
|
|
|
$restart_proxy = "yes";
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
// Change aliases
|
|
|
|
|
if (empty($_SESSION["error_msg"])) {
|
|
|
|
|