From d0748b2c4b25fb01706ae225c0181c2e25804a8a Mon Sep 17 00:00:00 2001 From: Erich Eckner Date: Wed, 4 Apr 2018 16:21:30 +0200 Subject: web-scripts/status.php new --- web-scripts/status.php | 30 ++++++++++++++++++++++++++++++ 1 file changed, 30 insertions(+) create mode 100644 web-scripts/status.php (limited to 'web-scripts') diff --git a/web-scripts/status.php b/web-scripts/status.php new file mode 100644 index 0000000..5050b4b --- /dev/null +++ b/web-scripts/status.php @@ -0,0 +1,30 @@ + + +Build master status\n"; +print "\n"; +print "\n"; +print "\n"; +print "Start page
\n"; + +$mysql = new mysqli("localhost", "webserver", "empty", "buildmaster"); +if ($mysql->connect_error) { + die("Connection failed: " . $mysql->connect_error); +} + +if ( ! $result = $mysql -> query( + "SELECT MAX(`package_sources`.`commit_time`) AS `last`" . + "FROM `package_sources`" + )) + die($mysql->error); + +if ($result -> num_rows > 0) { + + $row = $result->fetch_assoc(); + print "latest package source is from " . $row["last"] . ".
\n"; +} + +?> + + -- cgit v1.2.3-70-g09d2