add downloadable backup

This commit is contained in:
frederik
2024-11-10 18:17:11 +01:00
committed by Nachtzuster
parent ef86658b6b
commit cb8abd4f22
2 changed files with 23 additions and 1 deletions
+1 -1
View File
@@ -49,7 +49,7 @@ function update() {
<button type="submit" name="submit" value="sudo clear_all_data.sh" onclick="return confirm('Clear ALL Data? Note that this cannot be undone and will take up to 90 seconds.')">Clear ALL data</button>
</div>
</form>
</div>
<div><a href="scripts/backup.php" download ><button onclick="return confirm('Download backup? Note that this could take a long time.')">Download backup</button></a></div>
<?php
$cmd="cd ".$home."/BirdNET-Pi && sudo -u ".$user." git rev-list --max-count=1 HEAD";
$curr_hash = shell_exec($cmd);