Skip to content

Commit 0fbdb18

Browse files
author
Till Brehm
committed
Fixed #4678 Problems with autoinstaller (unattended setup)
1 parent f0e75c9 commit 0fbdb18

File tree

2 files changed

+10
-2
lines changed

2 files changed

+10
-2
lines changed

install/install.php

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -114,7 +114,11 @@
114114
if($path_parts['extension'] == 'php') {
115115
include_once $cmd_opt['autoinstall'];
116116
} elseif($path_parts['extension'] == 'ini') {
117-
$tmp = ini_to_array(file_get_contents('autoinstall.ini'));
117+
if(is_file('autoinstall.ini')) {
118+
$tmp = ini_to_array(file_get_contents('autoinstall.ini'));
119+
} else {
120+
$tmp = ini_to_array(file_get_contents($cmd_opt['autoinstall']));
121+
}
118122
if(!is_array($tmp['install'])) $tmp['install'] = array();
119123
if(!is_array($tmp['ssl_cert'])) $tmp['ssl_cert'] = array();
120124
if(!is_array($tmp['expert'])) $tmp['expert'] = array();

install/update.php

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -119,7 +119,11 @@
119119
if($path_parts['extension'] == 'php') {
120120
include_once $cmd_opt['autoinstall'];
121121
} elseif($path_parts['extension'] == 'ini') {
122-
$tmp = ini_to_array(file_get_contents('autoinstall.ini'));
122+
if(is_file('autoinstall.ini')) {
123+
$tmp = ini_to_array(file_get_contents('autoinstall.ini'));
124+
} else {
125+
$tmp = ini_to_array(file_get_contents($cmd_opt['autoinstall']));
126+
}
123127
if(!is_array($tmp['install'])) $tmp['install'] = array();
124128
if(!is_array($tmp['ssl_cert'])) $tmp['ssl_cert'] = array();
125129
if(!is_array($tmp['expert'])) $tmp['expert'] = array();

0 commit comments

Comments
 (0)