Commit c11c4f7d authored by vogelor's avatar vogelor

some improvements of the remote action "update ISPConfig"

parent 8143c392
......@@ -39,4 +39,5 @@ $wb['Merge'] = 'Merge';
$wb['Remote Users'] = 'Remote Benutzer';
$wb['Remote Actions'] = 'Remote Aktionen';
$wb['Do OS-Update'] = 'Betriebssystem Update ausführen';
$wb['Do ISPConfig-Update'] = 'ISPConfig auf den neuesten Stand bringen';
?>
......@@ -41,4 +41,5 @@ $wb['Merge'] = 'Merge';
$wb['Remote Users'] = 'Remote Users';
$wb['Remote Actions'] = 'Remote Actions';
$wb['Do OS-Update'] = 'Do OS-Update';
$wb['Do ISPConfig-Update'] = 'Do ISPConfig-Update';
?>
\ No newline at end of file
......@@ -159,6 +159,10 @@ $items[] = array( 'title' => 'Do OS-Update',
'target' => 'content',
'link' => 'admin/remote_action_osupdate.php');
$items[] = array( 'title' => 'Do ISPConfig-Update',
'target' => 'content',
'link' => 'admin/remote_action_ispcupdate.php');
$module['nav'][] = array( 'title' => 'Remote Actions',
'open' => 1,
'items' => $items);
......
......@@ -4,7 +4,7 @@
<div class="panel panel_language_add">
<div class="pnl_formsarea">
<fieldset class="inlineLabels"><legend>{tmpl_var name='do_osupdate_caption'}</legend>
<fieldset class="inlineLabels"><legend>{tmpl_var name='do_ispcupdate_caption'}</legend>
<div class="ctrlHolder">
<label for="server_select">{tmpl_var name='select_server_txt'}</label>
<select name="server_select" id="server" class="selectInput" onchange="document.getElementById('OKMsg').style.visibility = 'hidden'; ">
......@@ -18,7 +18,7 @@
</tmpl_if>
<div class="buttonHolder buttons">
<button class="positive iconstxt icoPositive" type="button" value="{tmpl_var name='btn_do_txt'}" onClick="submitForm('pageForm','admin/remote_action_osupdate.php');"><span>{tmpl_var name='btn_do_txt'}</span></button>
<button class="positive iconstxt icoPositive" type="button" value="{tmpl_var name='btn_do_txt'}" onClick="submitForm('pageForm','admin/remote_action_ispcupdate.php');"><span>{tmpl_var name='btn_do_txt'}</span></button>
</div>
</div>
......
......@@ -147,11 +147,15 @@ class remoteaction_core_module {
/*
* Do the update
*/
exec("cd /tmp");
$oldDir = getcwd();
chdir("/tmp");
exec("rm /tmp/ISPConfig-" . $new_version . ".tar.gz");
exec("rm /tmp/ispconfig3_install -R");
exec("wget http://www.ispconfig.org/downloads/ISPConfig-" . $new_version . ".tar.gz");
exec("tar xvfz ISPConfig-" . $new_version . ".tar.gz");
exec("cd ispconfig3_install/install");
chdir("/tmp/ispconfig3_install/install");
exec("touch autoupdate");
exec("php -q autoupdate.php");
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment