1
0
mirror of https://github.com/thooge/esp32-nmea2000-obp60.git synced 2025-12-14 14:33:07 +01:00

better handling of db connections, return timestamp for found builds

This commit is contained in:
andreas
2023-10-02 18:43:43 +02:00
parent 7a5da47e17
commit 707c00b850
3 changed files with 53 additions and 13 deletions

28
webinstall/create_db.php Normal file
View File

@@ -0,0 +1,28 @@
<?php
echo "CREATEDB\n";
include("functions.php");
$database=openDb();
if (! isset($database)){
die("ERROR: db not set\n");
}
try{
$sql="CREATE TABLE `CIBUILDS` (
`id` varchar(255) NOT NULL,
`tag` varchar(255),
`status` varchar(255) NOT NULL,
`config` longtext,
`environment` VARCHAR(255),
`buildflags` longtext,
`timestamp` timestamp ,
PRIMARY KEY (`id`)
);";
echo "executing $sql<br>";
$rt=$database->query($sql);
echo "execute OK<br>";
} catch (Exception $e){
echo "ERROR: ".$e;
}
?>