File tree Expand file tree Collapse file tree 1 file changed +8
-8
lines changed
Expand file tree Collapse file tree 1 file changed +8
-8
lines changed Original file line number Diff line number Diff line change 153153swriteln ($ inst ->lng (' Default values are in [brackets] and can be accepted with <ENTER>. ' ));
154154swriteln ($ inst ->lng (' Tap in "quit" (without the quotes) to stop the installer. ' ."\n\n" ));
155155
156- //** Check install dir is writable (probably not root or sudo)
157- if (!is_writable (dirname ('/usr/local/ispconfig ' ))){
158- die ("ERROR: Cannot write to the /usr/local/ispconfig directory. Are you root or sudo ? \n\n" );
156+ //** Check log file is writable (probably not root or sudo)
157+ define ('ISPC_LOG_FILE ' , $ conf ['ispconfig_log_dir ' ] . '/install.log ' );
158+ if (!is_writable (dirname (ISPC_LOG_FILE ))){
159+ die ("ERROR: Cannot write to the " .dirname (ISPC_LOG_FILE )." directory. Are you root or sudo ? \n\n" );
160+ }
161+
162+ if (!is_dir ($ conf ['ispconfig_log_dir ' ])) {
163+ mkdir ($ conf ['ispconfig_log_dir ' ], 0755 , true );
159164}
160165
161166//** Check for ISPConfig 2.x versions
302307 $ inst ->dbmaster = $ inst ->db ;
303308}
304309
305- if (!is_dir ($ conf ['ispconfig_log_dir ' ])) {
306- mkdir ($ conf ['ispconfig_log_dir ' ], 0755 , true );
307- }
308- define ('ISPC_LOG_FILE ' , $ conf ['ispconfig_log_dir ' ] . '/install.log ' );
309-
310310//* Create the mysql database
311311$ inst ->configure_database ();
312312
You can’t perform that action at this time.
0 commit comments