fix(install) : dump curl + fix mv

This commit is contained in:
mrflos 2023-02-01 16:48:41 +03:00
parent 286a5dafc2
commit e4b4426a30

View file

@ -229,9 +229,14 @@ function copyYesWikiFiles($domain, $user, $dbUser)
}
exec($sudo.'curl -o '.$tmpFile.' '.$_SERVER['source_archive_url']);
exec($sudo.'unzip '.$tmpFile.' "doryphore/*" -d '.$destDir);
exec($sudo.'mv '.$destDir.'/doryphore/* -d '.$destDir.'/');
exec($sudo.'mv '.$destDir.'/doryphore/* '.$destDir.'/');
exec($sudo.'rm -rf '.$destDir.'/doryphore');
unlink($tmpFile);
echo 'curl -X POST "https://'.$domain.'/?PagePrincipale&installAction=install" -F "config[default_language]=fr" -F "config[wakka_name]='.$domain.'" \
-F "config[root_page]=PagePrincipale" -F "config[mysql_host]=localhost" \
-F "config[mysql_database]='.$dbUser['database'].'" -F "config[mysql_user]='.$dbUser['user'].' -F "config[mysql_password]='.$dbUser['password'].'" -F "config[table_prefix]=yeswiki_" \
-F "admin_name='.$_SERVER['admin_id'].'" -F "admin_password='.$_SERVER['admin_password'].'" -F "admin_password_conf='.$_SERVER['admin_password'].'" \
-F "admin_email='.$_SERVER['admin_email'].'" -F "config[rewrite_mode]=1" -F "submit=Continue"';
exec($sudo.'curl -X POST "https://'.$domain.'/?PagePrincipale&installAction=install" -F "config[default_language]=fr" -F "config[wakka_name]='.$domain.'" \
-F "config[root_page]=PagePrincipale" -F "config[mysql_host]=localhost" \