Skip to content

Commit edf1894

Browse files
authored
Merge pull request hestiacp#2262 from jaapmarcus/fix/2261-edit-php81-404
Fix hestiacp#2261 edit php8.1-fpm service not found
2 parents 3bcbc4c + 1155603 commit edf1894

File tree

2 files changed

+10
-2
lines changed

2 files changed

+10
-2
lines changed

web/list/server/index.php

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -119,6 +119,15 @@
119119
exec (HESTIA_CMD."v-list-sys-info json", $output, $return_var);
120120
$sys = json_decode(implode('', $output), true);
121121
unset($output);
122+
123+
exec (HESTIA_CMD."v-list-sys-php json", $output, $return_var);
124+
$php = json_decode(implode('', $output), true);
125+
unset($output);
126+
$phpfpm = array();
127+
foreach($php as $version){
128+
$phpfpm[] = 'php'.$version.'-fpm';
129+
}
130+
122131
exec (HESTIA_CMD."v-list-sys-services json", $output, $return_var);
123132
$data = json_decode(implode('', $output), true);
124133
ksort($data);

web/templates/pages/list_services.html

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -118,8 +118,7 @@
118118
$spnd_icon = 'fa-play';
119119
$state_icon = 'fa-minus-circle status-icon red';
120120
}
121-
122-
if (($key == "php5.6-fpm") || ($key == "php7.0-fpm") || ($key == "php7.1-fpm") || ($key == "php7.2-fpm") || ($key == "php7.3-fpm") || ($key == "php7.4-fpm") || ($key == "php8.0-fpm")) {
121+
if(in_array($key, $phpfpm)){
123122
$edit_url="php";
124123
} else {
125124
$edit_url=$key;

0 commit comments

Comments
 (0)