File tree Expand file tree Collapse file tree 3 files changed +9
-9
lines changed
Expand file tree Collapse file tree 3 files changed +9
-9
lines changed Original file line number Diff line number Diff line change 8585 chdir ( realpath (dirname (__FILE__ )) );
8686}
8787
88- //** Install logfile
89- define ('ISPC_LOG_FILE ' , '/var/log/ispconfig_install.log ' );
9088define ('ISPC_INSTALL_ROOT ' , realpath (dirname (__FILE__ ).'/../ ' ));
9189
9290//** Include the templating lib
155153swriteln ($ inst ->lng (' Default values are in [brackets] and can be accepted with <ENTER>. ' ));
156154swriteln ($ inst ->lng (' Tap in "quit" (without the quotes) to stop the installer. ' ."\n\n" ));
157155
158- //** Check log file is writable (probably not root or sudo)
159- if (!is_writable (dirname (ISPC_LOG_FILE ))){
160- die ("ERROR: Cannot write to the " . dirname ( ISPC_LOG_FILE ). " directory. Are you root or sudo ? \n\n" );
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" );
161159}
162160
163161//** Check for ISPConfig 2.x versions
304302 $ inst ->dbmaster = $ inst ->db ;
305303}
306304
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+
307310//* Create the mysql database
308311$ inst ->configure_database ();
309312
Original file line number Diff line number Diff line change @@ -2982,9 +2982,6 @@ public function make_ispconfig_ssl_cert() {
29822982 }
29832983 swriteln ('Using certificate path ' . $ acme_cert_dir );
29842984
2985- if (!is_dir ($ conf ['ispconfig_log_dir ' ])) {
2986- mkdir ($ conf ['ispconfig_log_dir ' ], 0755 , true );
2987- }
29882985 $ acme_log = $ conf ['ispconfig_log_dir ' ] . '/acme.log ' ;
29892986
29902987 $ ip_address_match = false ;
Original file line number Diff line number Diff line change 8888if (realpath (dirname (__FILE__ )) != $ cur_dir ) die ("Please run installation/update from _inside_ the install directory! \n" );
8989
9090//** Install logfile
91- define ('ISPC_LOG_FILE ' , '/var/log/ispconfig_install.log ' );
9291define ('ISPC_INSTALL_ROOT ' , realpath (dirname (__FILE__ ).'/../ ' ));
9392
9493//** Include the templating lib
112111include_once "/usr/local/ispconfig/server/lib/config.inc.php " ;
113112$ conf_old = $ conf ;
114113unset($ conf );
114+ define ('ISPC_LOG_FILE ' , $ old_conf ['ispconfig_log_dir ' ] . '/update.log ' );
115115
116116if ($ dist ['id ' ] == '' ) die ('Linux distribution or version not recognized. ' );
117117
You can’t perform that action at this time.
0 commit comments