update
This commit is contained in:
@@ -255,6 +255,20 @@ if ($type == "git_pull") {
|
||||
echo $output;
|
||||
}
|
||||
|
||||
if ($type == "update_firmware") {
|
||||
// Execute the comprehensive update script
|
||||
$command = 'sudo /var/www/moduleair_pro_4g/update_firmware.sh 2>&1';
|
||||
$output = shell_exec($command);
|
||||
|
||||
// Return the output as JSON for better web display
|
||||
header('Content-Type: application/json');
|
||||
echo json_encode([
|
||||
'success' => true,
|
||||
'output' => $output,
|
||||
'timestamp' => date('Y-m-d H:i:s')
|
||||
]);
|
||||
}
|
||||
|
||||
if ($type == "set_RTC_withNTP") {
|
||||
$command = 'sudo /usr/bin/python3 /var/www/moduleair_pro_4g/RTC/set_with_NTP.py';
|
||||
$output = shell_exec($command);
|
||||
|
||||
Reference in New Issue
Block a user